Texture - Sprite Mapping

Started by
1 comment, last by freeworld 12 years, 6 months ago
Hi there,

I am looking for the name of a technique that is used in some social games.
Sometimes, there are some animations (e.g. characters) looking very 3D-ish, but they are prerendered and loaded from a spritesheet.
But the strange thing (at least for me) is, that this animations can have a lot of different textures on it... and indeed there is only one spritesheet and some textures for it.
So somehow the textures are rendered on it with a shader using the color channels of the spritesheet.

Now my question is: how is this technique called? Thanks a lot in advance for helping me. :)
Advertisement

So somehow the textures are rendered on it with a shader using the color channels of the spritesheet.


Usually this is done using layers in 2d, or just multitexturing in 3d, where each piece of clothing or skin tone is rendered separately to be combined later.

One can adjust the colour with a software (or the GPU), but applying a texture could look pretty bizarre because the texture would not conform to the shape of the body, and if you made it conform by deforming the texture on application based on a normal map of the character, it would probably negate the usefulness of the pre-rendering.


Can you show us a picture or video of this application?

Usually this is done using layers in 2d, or just multitexturing in 3d, where each piece of clothing or skin tone is rendered separately to be combined later.


Layers would be my prefered way. When changing colors, you should probably use a mask, to determine what pixels of your texture will actually have their colors changed.

of you can do it as blizzard did in Diablo/Diablo2 and render separate images for every possible combination of images, then use the mask as I described to determine what parts of the image can change color.Also you can look into how Tropico 1 and 2 managed different layers. Were each sprite had a separate sprite with depth values. To allow objects to move behind parts of a sprite, they just did z comparisons when drawing two images on top of each other for every pixel drawn. Not the most elegant way, but it works.
[ dev journal ]
[ current projects' videos ]
[ Zolo Project ]
I'm not mean, I just like to get to the point.

This topic is closed to new replies.

Advertisement