Hi,

I have a scene graph with multiple cameras as follow :

Camera 1 :
 - clear mask : color and depth
 - use FBO_Camera_1_Color as color buffer attachment
 - use FBO_Camera_1_Depth as depth buffer attachment

Camera 2 :
 - clear mask : none
 - use FBO_Camera_2_Color as color buffer attachment
 - use FBO_Camera_2_Depth as depth buffer attachment


Now, I would like the "Camera 2" :
 - to use "FBO_Camera_1_Color" as an INPUT color buffer (do not write into this 
buffer, write into "FBO_Camera_2_Color")
 - to use "FBO_Camera_1_Depth" as an INPUT depth buffer (do not write into this 
buffer, write into "FBO_Camera_2_Depth")

So this way :
 - "FBO_Camera_1_Color" and "FBO_Camera_1_Depth" remains intact even after 
camera 2 rendering.
 - everywhere the camera 2 do not write data, data from camera 1 are visible

The first solution would probably to copy FBOs before camera 2 rendering :
 - "FBO_Camera_1_Color" into "FBO_Camera_2_Color"
 - "FBO_Camera_1_Depth" into "FBO_Camera_2_Depth"

How to do that ? Should I use another camera and a renderquad to perform the 
copy, or is there any OSG functionnality to copy FBO ?


Even better, is there a second solution to provide an "input" buffer 
attachement to a camera ?


Thank you!

Aurelien

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=50713#50713





_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to