Hi Rick, I am afraid you are on your own - I will not be able to help much. Shadow mapping issues could be really hard ;-( I would need to grab similar board, roll up the sleeves and start debuging. But I don't have the time nor access to such hardware.
> [..] > When I just use StandardShadowMap (with the ShadowMap adjustment), the > shadows are correct. > (However, there is a small gap between the (shadow-casting) objects and > their shadow, possibly polygon offset-related?) Probably. I don't have another idea. > When I just use MinimalShadowMap or MinimalDrawBoundsShadowMap, the > shadows are correct, > but only when the bounding box (displayed when using setDebugDraw) of > the shadow-casting objects > is completely within view. When the bounding box is partially outside > the viewing frustum, the shadows > are correct only from certain viewpoint positions/orientations. If I > then move/aim the viewpoint, > the shadows move away from the objects that cast them (and eventually > disappear in some cases). > From just looking at the debug HUD, you could say that the shadows get > 'more correct' > when the (shadow-casting objects) bounding box is less 'deformed'. > Any ideas? It does not sound like easy one. Are you sure that ATI bug only affects texture application ? Maybe render to texture is also flipped somehow. I assume you have modified texgen matrix but not shadow camera projection matrix (the one involved in computation of texgen matrix) ? If shadow camera projection gets modified it could potentially affect rest of the code. Actually, one idea just came to my mind, MinimalDrawBoundsShadowMap does rough depth map prerender to compute visible shadowed scene extents. I suppose reverted vertical texture coordinates may also affect this code. You may look at MinimaDrawBounds line 203 - its the place where matrix for prerenderd image scan is computed - and you may need to make the fixes there. As a alternative approach, you could try LightSpacePerspectiveShadowMapCB and see if the problem is also present ? LightSpacePerspectiveShadowMapCB variant computes shadowed volume by scanning boxes around drawables in render bins and should avoid at least this potential prerenderd image scanning issue. > I will keep looking into tomorrow, starting at the MinimalShadowMap > level as this seems to be > the lowest level at which the problem occurs on my system. Good luck. And let me know if you come up with some constructive conclusion, possible fixes or workarounds. Cheers, Wojtek RE PS: > EMPTY_BOX: no shadows are visible, debug HUD shows an empty shadow map > BOUNDING_SPHERE: shadows visible from certain viewpoint > positions/orientations, but not > in the correct place. The debug HUD shows shadow map with projected > bounding box etc. Default setting may impact performance but should be safest. I am not 100% sure that other options are completely bug free so I would suggest not experimenting with this if you have other problems. Usage of these options also heavily depends on the light type. Leave it at default if you use spot or omnidirectional light. _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

