Terrain detail map lighting

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
ison
Posts: 42
Joined: Sun Mar 24, 2013 9:09 pm

Terrain detail map lighting

Post by ison »

Hello,
it seems that lighting doesn't work on detail maps.

Code: Select all

terrain->setMaterialFlag(video::EMF_LIGHTING, true);
 
    terrain->setMaterialTexture(0,
            driver->getTexture("../../media/terrain-texture.jpg"));
    terrain->setMaterialTexture(1,
            driver->getTexture("../../media/detailmap3.jpg"));
 
    terrain->setMaterialType(video::EMT_DETAIL_MAP);
Lighting only works on first texture but not on a detail map which is always 100% lit.
I'm using Irrlicht 1.8
chronologicaldot
Competition winner
Posts: 688
Joined: Mon Sep 10, 2012 8:51 am

Re: Terrain detail map lighting

Post by chronologicaldot »

What video driver are you using?
ison
Posts: 42
Joined: Sun Mar 24, 2013 9:09 pm

Re: Terrain detail map lighting

Post by ison »

OpenGL 3,
gfx card: nvidia geforce 9600m gt
Neirdan
Posts: 39
Joined: Tue Aug 14, 2012 10:29 pm

Re: Terrain detail map lighting

Post by Neirdan »

We talked about it on the IRC channel, I did the same test with irrlicht 1.7.3 / OpenGL and it doesn't work.

Add a terrain node with DETAIL_MAP material, set true LIGHNING flag, add no light source, the first texture is black but the detail texture is visible.
Post Reply