Dear all,

I have been trying to apply osgPPU for stereo rendering and that
appeared to work. However, when I took a closer look at the anaglyph
rendering of the osgppu_dof example (run it with --stereo), I noticed
that it does not work as expected (running the osgPPU pipeline on both
views, then applying anaglyph), even though it kind of looks
plausible. What happens instead is that the "left" render pass
executes the pipeline on a red cow (osg uses colormasks for rendering
the anaglyph). In the second pass, osg additionally renders the cyan
parts into the same input texture and runs the "right" pipeline pass
based on it. For the second frame, the input texture is still the
previous anaglyph with updated red-channel. Both passes are using the
correct depth buffer for their view.

This problem is bugging me, as the same stereo pipeline works
correctly with quad-buffered stereo.

I think the fix would be to render both left and right views in full
colour and then combine them in a shader to compute the final anaglyph
image. This way it would also be possible to support other types of
anaglyph, such as red-blue, green-magenta [1] or blue-amber [2], which
may not be easily implemented using RGB colour masks.

My question is: would this be a useful modification of osg? What do
other people think?

Thanks,
Christian.

[1] <http://www.3dglassesonline.com/trioscopics/>
[2] <http://www.colorcode3d.com/Home.html>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to