Making a shader use only part of its texture
Hi there.
I need a shader that can be used to render a frame of a spritemap to a quad primitive. The spritemap contains many cells (about 30 columns and 10 rows) of animation frames.
I've been trying to figure out how to provide TextureUV's to a surface shader so that it draws that part of the texture on the quad, but I'm not sure where I should be looking for that.
This must be done in the shader because I need to do it via PropertyBlocks.
The image below might help illustrate what I'm after.
Thanks in advance.
Your answer
Follow this Question
Related Questions
Rendering objects in the same position 0 Answers
Help with a custom "painting" shader 1 Answer
How to add a normal map "support" to this shader? 0 Answers
How to make a filter for my Camera? 0 Answers
Bump maps in replacement shaders 0 Answers