MutiTexturing
-
- Posts: 50
- Joined: Thu Aug 13, 2009 7:16 am
- Location: India
MutiTexturing
How to do multitexturing in Irrlicht?
Some formats might already support that (don't know which ones right now).
If you want to do it by hand then you first have to set a material which supports more than one texture. Check the MaterialType documentation to find out what each material does. Next you have to make sure your mesh has the right vertex format (usually S3DVertex2TCoords). And lastly you have to set the other texture(s). It seems for OpenGL you can even ignore setting the vertex format if you don't need a second set of UV-coordinates as for multitexture materials a copy of the UV's of the first texture will be passed.
If you want to do it by hand then you first have to set a material which supports more than one texture. Check the MaterialType documentation to find out what each material does. Next you have to make sure your mesh has the right vertex format (usually S3DVertex2TCoords). And lastly you have to set the other texture(s). It seems for OpenGL you can even ignore setting the vertex format if you don't need a second set of UV-coordinates as for multitexture materials a copy of the UV's of the first texture will be passed.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm