Fading with Irrlicht.NET

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
ctt
Posts: 8
Joined: Wed Mar 16, 2005 11:15 pm

Fading with Irrlicht.NET

Post by ctt »

I am trying to fade a ISceneNode in Irrlicht.Net, but cannot find the property to modify (alpha value maybe?). Anybody? Thanks
phrounz
Posts: 45
Joined: Thu Feb 10, 2005 11:45 am
Location: France
Contact:

Post by phrounz »

Maybe I don't understand what you want to do but it could be just :

Code: Select all

gui::IGUIInOutFader* fader =device->getGUIEnvironment()->addInOutFader();
fader->setColor(color);
fader->fadeIn(time);
this code fade the whole screen.

I you want to fade just one node, I suggest you to use a material with EMT_TRANSPARENT_ADD_COLOR type and change several times the texture, using for example textures which are blacker and blacker to fade out (so the node will be more and more transparent).
ctt
Posts: 8
Joined: Wed Mar 16, 2005 11:15 pm

Post by ctt »

Unfortunately, the Irrlicht.NET library lacks the IGUIInOutFader, but the second suggestion on making multiple textures does work even though it is a bit convoluted. Any suggestions on how to fade out a ILightSceneNode.. I tried modifying the radius of the light, but I get strange results.. again with the Irrlicht.NET library.
Post Reply