CCloudSceneNode - clouds with levels of detail

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
Vsk
Posts: 343
Joined: Thu Sep 27, 2007 4:43 pm

Post by Vsk »

My clouds have some green colour????
Where come it from?

My terrain has some green texture, is the only think that can be, but in your demo you have too a green textur but no green colour in your clouds.
What could it be?

Realy great work!!! keep it up.
Vsk
Posts: 343
Joined: Thu Sep 27, 2007 4:43 pm

Post by Vsk »

If I turn on the light for clouds then there is no green colour but It hasn't the rain day effect (gray).
Why do you have the light off? I don't understand that commentary about the normal, I'don't see anythin ungly with light on (at least using cloud4.jpg).
So what could it be that without light I have some green coluour in some clouds?.
Thanks in advance.
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

I can't look at this at the moment, it's been a long time since I looked at the code. I've kind of abandoned this project anyway.. I have a much better idea for volumetric clouds with self-shadowing, light shafts etc but have not got around to implementing it yet.
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
m3ltd0wn
Posts: 107
Joined: Wed Dec 12, 2007 8:32 am
Location: Romania

reply

Post by m3ltd0wn »

i have some problems with this cloud scene node in irrlicht 1.4.1.
here goes: the clouds are rendered..but the textures no, the program is loading all the textures though, but the clouds appear like black sqares on the sky :(


any suggestions ?
Dorth
Posts: 931
Joined: Sat May 26, 2007 11:03 pm

Post by Dorth »

... go through debug tests?
m3ltd0wn
Posts: 107
Joined: Wed Dec 12, 2007 8:32 am
Location: Romania

reply

Post by m3ltd0wn »

no success :(

something is wrong in the code..cuz the cloud can't display the texture...though the texture is successfully loaded.

i've tried not to use alpha channels... just solid... and again..the texture doesn't show... there are only black squares on the sky :(
Dorth
Posts: 931
Joined: Sat May 26, 2007 11:03 pm

Post by Dorth »

Yes, but you have the code, for both the node and the engine.
Split the task into tasklets. Test subsections of the code, parts of the nodes, etc. Make sure that the functions the node calls haven't had major changes. Then test that they do what they are supposed properly. Then go through the code, logging what must be and testing it all. Debugging is so often more programming than coding itself.
m3ltd0wn
Posts: 107
Joined: Wed Dec 12, 2007 8:32 am
Location: Romania

reply

Post by m3ltd0wn »

i know that :) but i'm not so advanced in programming :) that is why i ask for some help here :)

if i knew how to do it i wouldn't ask hehe :)
Frank Dodd
Posts: 208
Joined: Sun Apr 02, 2006 9:20 pm

Post by Frank Dodd »

I was having the same problem, I rebuilt the class using 1.4.2 and all of the clouds appeared as black squares.

I found that for some reason the material properties were not being set, if after the line: -

Code: Select all

clouds->setMaterialTexture( 0, txture );
you put the lines: -

Code: Select all

clouds->getMaterial(0).TextureLayer[0].Texture = txture;
clouds->getMaterial(0).Lighting = false;
clouds->getMaterial(0).MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL;
The program will work. Strangely the setMaterialFlag, setMaterialType and setMaterialTexture calls were not working on material properly. Altering ISceneNode.h to print pointer values showed that the Material and texture addresses were not the same inside the call as they were when set using the code above and compiling with gcc 3.4.5 mingw special.

This is just a work around its certainly not a fix and its also a bit worrying. However that aside once working the clouds do look pretty cool :D
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

This seems to be an issue with non-overridden methods from ISceneNode, or maybe just missing proper signatures to fulfill the proper resolution of the virtual methods. I'll upload some new versions of the irrExt packages soon, as I've already fixed some other issues with some other extensions.
m3ltd0wn
Posts: 107
Joined: Wed Dec 12, 2007 8:32 am
Location: Romania

Post by m3ltd0wn »

hey that worked out nicely with irr 1.4.2 :)

10x

great community ;)
Frank Dodd
Posts: 208
Joined: Sun Apr 02, 2006 9:20 pm

Post by Frank Dodd »

I just had to update some custom scene nodes to 1.4.2 that had similar problems to the cloud node. After looking into it again it became obvious that the interface on the class has changed at some point: -

Code: Select all

virtual video::SMaterial& getMaterial(u32 i) = 0;
virtual u32 getMaterialCount() const = 0;
must have been something like: -

Code: Select all

virtual video::SMaterial& getMaterial(s32 i) = 0;
virtual u32 getMaterialCount() = 0;
Correcting the interface so that it matches the updated ISceneNode corrects the problem in the other nodes.
Katsankat
Posts: 178
Joined: Sun Mar 12, 2006 4:15 am
Contact:

Post by Katsankat »

The demo works fine, however after compilation with Irrlicht 1.5, clouds are here but totally black, any idea why?
From this code : http://irrlicht-plugins.googlecode.com/ ... ode/media/
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

The clouds code, as well as other extensions, can now be found under the irrExt project on SourceForge. Please grab updated code from there. We'll release a 1.5 compatible package soon.
wing64
Competition winner
Posts: 242
Joined: Wed Jul 23, 2008 2:35 am
Location: Thailand
Contact:

Post by wing64 »

cloud scene node for 1.5
screenshot
Image
code
http://www.geocities.com/zaros64/CCloudSceneNode015.zip
enjoy downloading. :)
Post Reply