If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
lobo-tuerto
Posts: 8 Joined: Sat Apr 12, 2008 4:14 pm
Post
by lobo-tuerto » Mon May 12, 2008 3:59 am
Hello guys,
I would like some pointers about how setMaterialTexture works. I'm trying to assign two textures to a model.
The first texture is the naked body in layer 0, and the second texture are the clothes in layer 1 (same size as body but with alpha channel so some parts of the body can be seen through).
Code: Select all
node->setMaterialTexture(0, driver->getTexture("body.tga"));
node->setMaterialTexture(1, driver->getTexture("clothes.tga"));
But it isn't working, what's the correct way to do it?
Blog:
Lobo tuerto
En tierrra de ciegos, el tuerto es rey.
lobo-tuerto
Posts: 8 Joined: Sat Apr 12, 2008 4:14 pm
Post
by lobo-tuerto » Mon May 12, 2008 12:41 pm
Yeah I have looked at those, that's why I'm asking about it in this beginner's forum.
Blog:
Lobo tuerto
En tierrra de ciegos, el tuerto es rey.
piiichan
Posts: 59 Joined: Thu May 01, 2008 1:20 am
Location: New Caledonia (France - Pacific)
Contact:
Post
by piiichan » Mon May 12, 2008 1:19 pm
I tried all different material types, putting the textures into different texture layers and also into different materials .... without success
If somebody comes with a solution, I would also be interested to learn how to put a texture onto another
lobo-tuerto
Posts: 8 Joined: Sat Apr 12, 2008 4:14 pm
Post
by lobo-tuerto » Mon May 12, 2008 2:21 pm
Hmmm.... reading about other topics I heard about a render to texture feature, but I would like to know if that's the only method to achieve this.
So basically everytime your char changes clothes or "armor" you would have to render to texture then apply that texture to your model, right?
Blog:
Lobo tuerto
En tierrra de ciegos, el tuerto es rey.