Hi,

Guy wrote:
> Hello,
>  In continue to what I said before, I don't believe it's possible to
> change the subgraphs MRT definitions, since all the subgraph under the
> camera renders to the camera attachments. So if the camera is using MRT,
> then all the subgraph is rendered MRT.
>  The differences in the subgraphs could be the shaders using or not
> using the MRTs.
Mixing shaders in the subgraph that have different target requirements 
would definately be a problem, but I don't think there is an easy 
workaround for this.

> 
>  That brings the issue that if shaders use MRT and we didn't set the
> attachments correctly, a problem will occur.
Yes, this is also true. Care must be taken with the setup, just as with 
a lot of the other OpenGL state.

> 
>  So what I think should happen is that whether using StateSet attribute
> to declare the need for MRT by sub-graphs or by testing the Shaders, the
> camera should activate some visitor on it's sub-graph, find the draw
> buffers required, and then setup itself for the maximum need. But then
> the setting would be the same for the whole sub-graph.
I would place this functionality at a different level than the Camera. 
Potentially all the functions are already in OSG to do the visitor 
yourself before attaching the subgraph to the camera and setting up the 
camera. This is an example of the two sided coin: "Should OSG try to 
protect the user and infer intentions and possibly disallow some 
conbination of settings" or "Should it listen to explicit instructions". 
The current implementation follows the explicit path, but once we see 
how it is being used it could possibly change.

> 
> Does it makes sense?
Yes, all the comments are valid. We should maybe create a todo list for 
MRT, but I hope to get something in so people can start playing with it.

> 
> Thanks,
>  Guy.
cheers
jp


-- 
This message is subject to the CSIR's copyright terms and conditions, e-mail 
legal notice, and implemented Open Document Format (ODF) standard. 
The full disclaimer details can be found at 
http://www.csir.co.za/disclaimer.html.

This message has been scanned for viruses and dangerous content by MailScanner, 
and is believed to be clean.  MailScanner thanks Transtec Computers for their 
support.

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

Reply via email to