I've found out that the glitches are fixed by simply recreating
ShadowTechnique (SoftShadowMap).
If anyone is interested, here's the working example:
https://dl.dropboxusercontent.com/u/12634473/osg/osg_recreate_window_fixed.tar.bz2

2013/4/21 michael kapelko <[email protected]>

> For those who only read forum, here's the link to the full source code:
> https://dl.dropboxusercontent.com/u/12634473/osg/osg_recreate_window.tar.bz2
>
> 2013/4/20 michael kapelko <[email protected]>
>
>> Hi.
>> I'm implementing video settings change (and thus window recreation) in my
>> game without game restart. I experience graphics glitches after re-running
>> Viewer 3rd time: http://youtu.be/xOgTjENn2MM
>>
>> I recreate the window the following way:
>> * Stop the viewer, stop threading.
>> * Create new graphics context and attach it to the camera.
>> * Run the viewer again.
>>
>> As seen in the video, ShadowedScene does not survive the 3rd Viewer
>> restart and there appear some OpenGL errors in the logs.
>>
>> Can anybody help me, please?
>> Thanks.
>>
>> PS: Full source code is attached to the mail, uses CMake and needs
>> OpenSceneGraph-Data to run (dumptruck model), Page down recreates the
>> window.
>>
>
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to