shadow speckles
shadow speckles
Hi
My shadows have speckles in them Almost like the model has lots of small holes in it which keep dissapearing and appearing.
How can I fix this?
Here's a screenshot:
http://www.freepgs.com/defilter/images/ ... eckles.png
the speckles change every frame. you'll have to copy the link to get it work
Thanks
My shadows have speckles in them Almost like the model has lots of small holes in it which keep dissapearing and appearing.
How can I fix this?
Here's a screenshot:
http://www.freepgs.com/defilter/images/ ... eckles.png
the speckles change every frame. you'll have to copy the link to get it work
Thanks
no
I've googled z fighting and tried suggestions - larger znear, closer zfar but to no avail
is there a way in irrlicht to increase the zbuffer accuracy? and what is it by default?
a quote from a website: "glDepthFunc(GL_LEQUAL); // we put it again to LESS or EQUAL (or else you will get some z-fighting)"
*wonders if GL_LEQUAL is set*
although I suppose it must be all correct or other people would have problems.
I've googled z fighting and tried suggestions - larger znear, closer zfar but to no avail
is there a way in irrlicht to increase the zbuffer accuracy? and what is it by default?
a quote from a website: "glDepthFunc(GL_LEQUAL); // we put it again to LESS or EQUAL (or else you will get some z-fighting)"
*wonders if GL_LEQUAL is set*
although I suppose it must be all correct or other people would have problems.
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Code: Select all
$ grep -r GL_LEQUAL .
./COpenGLDriver.cpp: glDepthFunc(GL_LEQUAL);
./COpenGLDriver.cpp: glDepthFunc(GL_LEQUAL);
./COpenGLDriver.cpp: glDepthFunc( GL_LEQUAL );
Did you try the same with DirectX? Spintz produced a fix for it to keep the FPU precision high if set to high in your settings. IIRC there is the possibility to have 16bit and 32bit zbuffer and Irrlicht usually reset it to 16bit without this fix. Maybe the same holds still for OpenGL in some occasions?
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Another short update n this topic. The problem is easily reproducable: Start the SpecialFX example and turn on real-time shadows. You'll the the errors right behind the dwarf on the topmost step. At least for the unpatched irrlicht-1.0. I could not see this problem in irrlicht-0.14.
xDan, could you please try your app with 0.14? I'll check the source diff where the probably causes could lie.
xDan, could you please try your app with 0.14? I'll check the source diff where the probably causes could lie.
-
- Posts: 48
- Joined: Thu Jun 15, 2006 6:35 pm
Hybrid:
It may not be a problem with Irrlicht at all, the dwarf mesh has a gap under its head to save on polygons, its not visible unless you take the body away. Maybe someone skilled in modelling can fill it in and hopefully it will fix this.
Off topic:
Irrlicht’s shadow system is very limited (eg options in turn self shadowing off, what meshes receive shadows, etc) are there any future plans to improve this?
It may not be a problem with Irrlicht at all, the dwarf mesh has a gap under its head to save on polygons, its not visible unless you take the body away. Maybe someone skilled in modelling can fill it in and hopefully it will fix this.
Off topic:
Irrlicht’s shadow system is very limited (eg options in turn self shadowing off, what meshes receive shadows, etc) are there any future plans to improve this?
-
- Posts: 48
- Joined: Thu Jun 15, 2006 6:35 pm
^ I very much doubt it, if xDans problem is anything like mine, it appears that there are loads of TINY holes (like the size of a pixel) but I am certain it is not a problem with holes in the mesh, that is simply the easiest way to describe how it looks... and also the models I am using are all closed volumes.
can you provide a screenshot? what's your graphics card? does it happen in OGL? can you provide a model file? is the recieving surface flat, or bumpy? does it only happen when the shadow is over certain type of material? have you tried the latest svn version of irrlicht?
if we can get enough info and a repeatable test case together this thread can be moved to bug reports.
if we can get enough info and a repeatable test case together this thread can be moved to bug reports.