Detail and map textures for terrain..

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.
Post Reply
Dogs
Posts: 195
Joined: Wed Sep 15, 2004 1:04 am
Location: michigan

Detail and map textures for terrain..

Post by Dogs »

Ok this is the last one im posting today..
Sorry to be a pest...lol

Ok I know there is a way to do this but not sure how to do it in irrlicht but what i want to do is use a detail texture and tile it on my terrian and then have that be my bace texture...
Then id like to add another texture that is transparent in areas that I can lay over the entire terrians surface without tileing it and using this texture as the grassy parts and stone parts or so on...
The code below just lets me apply one texture to my terrain how would one sugest how i do this...?

video::IImage* iHeightMap = driver->createImageFromFile("../../media/map.bmp");
video::IImage* iTerrain = driver->createImageFromFile("../../media/texture.jpg");

scene::IAnimatedMesh* iTerrainMesh = smgr->addTerrainMesh("iTerrainMesh", iTerrain,iHeightMap,
core::dimension2d< f32 >(500.0f, 500.0f), 1200.0f, core::dimension2d< s32 >(64, 64) );
smgr->getMeshManipulator()->makePlanarTextureMapping(iTerrainMesh->getMesh(0), 0.0100f);
scene::ISceneNode* iTerrainNode = smgr->addOctTreeSceneNode(iTerrainMesh);
iTerrainNode->setPosition(core::vector3df(70,500,1000));
iTerrainNode->setMaterialFlag(EMF_FOG_ENABLE,true);





Any ideas would be great...
Dogs
Posts: 195
Joined: Wed Sep 15, 2004 1:04 am
Location: michigan

Post by Dogs »

Hmm no one knows how to apply two textures to a terrian?
zenprogramming not online

Post by zenprogramming not online »

the irrlicht-command addTerrainSceneNode uses a detailtexture, but Niko says the command is alphaversion.

Many months ago kortyburns from france and i made an example for terrain (and one example with detailmap, too) , look to
http://zenprogramming.tripod.com
Post Reply