Re: [osg-users] Multiple render targets not working.

2014-11-26 Thread Sander Meessen
I (sort of) solved the problem. I re-implemented the camera system according the Cookbook chapter 6 (which I only used partially the previous time) and frame buffer objects and multiple render targets worked. It was a combination of wrong camera settings and scene hierarchy. Although I did run

Re: [osg-users] Multiple render targets not working.

2014-11-25 Thread Julien Valentin
I gave you the code ...can't do more -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=61855#61855 ___ osg-users mailing list osg-users@lists.openscenegraph.org

[osg-users] Multiple render targets not working.

2014-11-24 Thread Sander Meessen
Hi, I have a problem when using multiple color buffer render targets. If I use one color buffer everything works fine, but when I use two; the render result always ends up in the last buffer and the first one remains blank. I have used the osgmultiplerendertargets example as a guide. My main

Re: [osg-users] Multiple render targets not working.

2014-11-24 Thread Julien Valentin
seams there's a problem in camera setup,but you didn't give it... There's plenty of entries in osg forum concerning RTT camera setup.. hope the further code help Code: setClearMask(GL_COLOR_BUFFER_BIT); // setClearMask( GL_COLOR_BUFFER_BIT);

Re: [osg-users] Multiple render targets not working.

2014-11-24 Thread Sander Meessen
[quote=mp3butcher]seams there's a problem in camera setup,but you didn't give it... There's plenty of entries in osg forum concerning RTT camera setup.. hope the further code help [code] setClearMask(GL_COLOR_BUFFER_BIT); setClearColor(osg::Vec4(0.0f, 0, 0, 0.0f));

Re: [osg-users] Multiple Render Targets Multisampling

2011-04-11 Thread J.P. Delport
] Multiple Render Targets Multisampling Hi, Has anyone tried to do any advanced* multisampled post effect using osg? If yes, I would like to know the best osg path to achieve this. *deferred rendered for example I have tried to attach a texture to a camera along

Re: [osg-users] Multiple Render Targets Multisampling

2011-04-08 Thread dimi christop
@lists.openscenegraph.org Sent: Thu, April 7, 2011 11:39:20 AM Subject: [osg-users] Multiple Render Targets Multisampling Hi, Has anyone tried to do any advanced* multisampled post effect using osg? If yes, I would like to know the best osg path to achieve this. *deferred rendered for example I have

Re: [osg-users] Multiple Render Targets Multisampling

2011-04-08 Thread Anthousis Andreadis
, 2011 11:39:20 AM Subject: [osg-users] Multiple Render Targets Multisampling Hi, Has anyone tried to do any advanced* multisampled post effect using osg? If yes, I would like to know the best osg path to achieve this. *deferred rendered for example I have tried to attach a texture to a camera

[osg-users] Multiple Render Targets Multisampling

2011-04-07 Thread Anthousis Andreadis
Hi, Has anyone tried to do any advanced* multisampled post effect using osg? If yes, I would like to know the best osg path to achieve this. *deferred rendered for example I have tried to attach a texture to a camera along with the multipleSamples and multisampleColorSamples values. This

Re: [osg-users] multiple render targets / cameras

2009-06-17 Thread Robert Osfield
Hi Bob, The answer is almost always answered by answering the simple question - no you logically have two separate views or do the two cameras that are taken the pictures share the same view. In your case it does sound like you have a single view, but two ways of rendering it - so you don't have

Re: [osg-users] multiple render targets / cameras

2009-06-16 Thread Bob Youmans
Hi, thanks for the great advice. if i'm going to have 2 render targets, one a memory image (ultimately custom shader) and one the GUI view window, should i still use Viewer, or CompositeViewer? It would be nice to be able to turn off the visible one for more performance. They will have

Re: [osg-users] multiple render targets / cameras

2009-06-09 Thread Jason Daly
Mike Wozniewski wrote: It's probably osgViewer::CompositeViewer that you want, not osgViewer::Viewer. There's an example in the source. That way you create two different osgViewer::Views, and each can have it's own manipulator. I'm not sure why you'd need a CompositeViewer if both cameras

[osg-users] multiple render targets / cameras

2009-06-08 Thread Bob Youmans
Hi, thanks to the gurus for all the excellent guidance you provide to us lesser mortals.. I can likely mush my way through this but I wanted to ask the opinions of the osg gurus on my design approach before getting mired down in a less desirable approach. We have a geometry graph that we

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Jason Daly
Bob Youmans wrote: My questions are currently: 1.What’s the best way to connect the two cameras so they’re the same position orientation, only rendering to different targets (e.g., update the matrix of one with the other using an update traversal, put both under a transform node in

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Bob Youmans
Hi, about the view and slave cameras, i got it, thanks. one is the lo-res view for the GUI and the other is the hi-res (prerender) view for the memory bitmap. does it matter for the master/slave status for prerender vs the displayed camera. Also, how does one turn these on/off? is that easy

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Bob Youmans
Hi, regarding matrixmanipulators, almost all the example have TrackBallManipulator as the view's manipulator, separater from the cameras. So, if i have an update callback on a camera to set its (and its slave) position and orientation, how does that interact with a trackballmanipulator. can

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Jason Daly
Bob Youmans wrote: Hi, about the view and slave cameras, i got it, thanks. one is the lo-res view for the GUI and the other is the hi-res (prerender) view for the memory bitmap. does it matter for the master/slave status for prerender vs the displayed camera. I don't believe it will

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Jason Daly
Bob Youmans wrote: Hi, regarding matrixmanipulators, almost all the example have TrackBallManipulator as the view's manipulator, separater from the cameras. So, if i have an update callback on a camera to set its (and its slave) position and orientation, how does that interact with a

Re: [osg-users] multiple render targets / cameras

2009-06-08 Thread Mike Wozniewski
It's probably osgViewer::CompositeViewer that you want, not osgViewer::Viewer. There's an example in the source. That way you create two different osgViewer::Views, and each can have it's own manipulator. The control is up to you, but if you want automated rotations and panning, I usually use

[osg-users] Multiple render targets

2008-04-06 Thread zhangguilian
Hi, As far as I know MRT is not supported in some ealier version of OSG, there is no call to glDrawBuffers (as opposed to glDrawBuffer) which is needed for MRT. I don't know current vesion of OSG supprot it or not, if not ,is there any solutions available in the osg community today? I would

Re: [osg-users] Multiple render targets

2008-04-06 Thread Guy
To: osg-users Subject: [osg-users] Multiple render targets Hi, As far as I know MRT is not supported in some ealier version of OSG, there is no call to glDrawBuffers (as opposed to glDrawBuffer) which is needed for MRT. I don't know current vesion of OSG supprot it or not, if not ,is there any

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Guy
Kifak-Hey) :) Thanks, Guy. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of J.P. Delport Sent: Tuesday, April 01, 2008 2:57 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi Art, Art Tevs

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Guy
:[EMAIL PROTECTED] On Behalf Of Robert Osfield Sent: Tuesday, April 01, 2008 3:40 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi Art J.P, I'm curious about the going for a custom StateAttribute for DrawBuffers. In terms of encapsulation

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of J.P. Delport Sent: Tuesday, April 01, 2008 2:57 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi Art, Art Tevs wrote

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Guy
Hi, Since the change I suggest is very small from what JP has implemented I don't submit files here just the differences: I removed getDrawBuffers and setDrawBuffers from the Camera.cpp / h In RenderStage the changes are as follows: RanderStage //.h Added vector of GLEnum named _drawBuffers.

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
] [mailto:[EMAIL PROTECTED] On Behalf Of J.P. Delport Sent: Tuesday, April 01, 2008 2:57 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi Art, Art Tevs wrote: Hi J.P. I am also using MRT, however completely without

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi Guy and J.P, Still struggling to keep up, partly cause I'm a bit cold on the subject, and partly because I've gone done with a rather pesky cold... On Wed, Apr 2, 2008 at 10:47 AM, J.P. Delport [EMAIL PROTECTED] wrote: Selecting glDrawBuffer/s according to the attachment map does make

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
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

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
Hi, Robert Osfield wrote: Hi Guy and J.P, Still struggling to keep up, partly cause I'm a bit cold on the subject, and partly because I've gone done with a rather pesky cold... On Wed, Apr 2, 2008 at 10:47 AM, J.P. Delport [EMAIL PROTECTED] wrote: Selecting glDrawBuffer/s according to

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi J.P, I'm sure you will see that there is no magic to my current implementation. The difficult part is to figure out when to enable it. Can we not just do it when COLOR_BUFFER1 upwards are enabled? Problem is that enabling MRT with just COLOR_BUFFER0 and then using

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
Hi, Robert Osfield wrote: Hi J.P, I'm sure you will see that there is no magic to my current implementation. The difficult part is to figure out when to enable it. Can we not just do it when COLOR_BUFFER1 upwards are enabled? Problem is that enabling MRT with just

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi J.P, On Wed, Apr 2, 2008 at 1:10 PM, J.P. Delport [EMAIL PROTECTED] wrote: Rather than ban this type of usage perhaps we could come up with another scheme. Would making COLOR_BUFFER0 be separate from COLOR_BUFFER be a way around this, i.e. if the use wants MRT then they

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi J.P, On Wed, Apr 2, 2008 at 1:30 PM, Robert Osfield [EMAIL PROTECTED] wrote: I will tweak the osg::Camera API to differentiate between COLOR_BUFFER and COLOR_BUFFER0 but not merge your changes to Camera and RenderStage right now. I will also tweak your example to work with the new Camera

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
Hi, Guy wrote: Hi, Since the change I suggest is very small from what JP has implemented I don't submit files here just the differences: I removed getDrawBuffers and setDrawBuffers from the Camera.cpp / h In RenderStage the changes are as follows: RanderStage //.h Added vector of

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Guy
. Delport Sent: Wednesday, April 02, 2008 2:11 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi, Robert Osfield wrote: Hi J.P, I'm sure you will see that there is no magic to my current implementation. The difficult part

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread J.P. Delport
] [mailto:[EMAIL PROTECTED] On Behalf Of J.P. Delport Sent: Wednesday, April 02, 2008 2:11 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi, Robert Osfield wrote: Hi J.P, I'm sure you will see that there is no magic to my

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi J.P, Guy and Art et. al, On Wed, Apr 2, 2008 at 3:53 PM, J.P. Delport [EMAIL PROTECTED] wrote: When the visitor is implemented, if a node is using MRT it's probably because the user attached a shader that uses gl_Data[], and then it will set on the flag whether it has one or many COLOR

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Guy
shaders. Guy. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of J.P. Delport Sent: Wednesday, April 02, 2008 4:54 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi, Guy wrote: Hi, Using MRT

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-02 Thread Robert Osfield
Hi All, I've just merged J.P changes to RenderStage to add support for glDrawBuffers in conjunction with my tweak to osg::Camera::COLOR_BUFFER0. J.P's osgmultiplerendertargets example is also now checked into SVN. Robert. ___ osg-users mailing list

Re: [osg-users] Multiple Render Targets - Request for Comments/Testing

2008-04-01 Thread Robert Osfield
Hi J.P, On Tue, Apr 1, 2008 at 11:29 AM, J.P. Delport [EMAIL PROTECTED] wrote: is anyone looking at this, or should I assume no news is good news and just submit it as a patch? I'm afraid I haven't yet had a chance to test, feel free to submit the changes. Robert.

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-01 Thread Wojciech Lewandowski
] To: OpenSceneGraph Users osg-users@lists.openscenegraph.org Sent: Tuesday, April 01, 2008 12:29 PM Subject: Re: [osg-users] Multiple Render Targets - Request forComments/Testing Hi, is anyone looking at this, or should I assume no news is good news and just submit it as a patch? rgds jp J.P

Re: [osg-users] Multiple Render Targets - Request for Comments/Testing

2008-04-01 Thread J.P. Delport
Hi, is anyone looking at this, or should I assume no news is good news and just submit it as a patch? rgds jp J.P. Delport wrote: Hi, over the weekend I have consolidated previous hacks to enable MRT into what I hope would be an acceptable patch for OSG. I would like to have it tested

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-01 Thread Art Tevs
Hi J.P. I am also using MRT, however completely without osg::Camera. However since I am working with FBOs directly I would prefer to have something like an extra StateAttribute or something which should setup the MRT. Or maybe the setDrawBuffers as an extra method in the FBO code. I think

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-01 Thread J.P. Delport
Hi Art, Art Tevs wrote: Hi J.P. I am also using MRT, however completely without osg::Camera. Yes, I've compiled osgPPU and ran the examples; cannot say that I fully understand the code yet :) However since I am working with FBOs directly I would prefer to have something like an extra

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-01 Thread Robert Osfield
Hi Art J.P, I'm curious about the going for a custom StateAttribute for DrawBuffers. In terms of encapsulation osg::Camera isn't a bad place for it, as there is already lots of RTT support there already. If there are cases when you want to enable/disable different combinations of DrawBuffers

Re: [osg-users] Multiple Render Targets - Request forComments/Testing

2008-04-01 Thread Art Tevs
Hi Robert, J.P., Of course the camera is a good place for it. However I would also prefer to have it somewhere else, because I am not always using cameras to make render to texture. Ok, maybe I am the one who is using the FBOs and RTT functionality out of the camera ;-) Hmm, maybe I was to fast

[osg-users] Multiple Render Targets - Request for Comments/Testing

2008-03-31 Thread J.P. Delport
Hi, over the weekend I have consolidated previous hacks to enable MRT into what I hope would be an acceptable patch for OSG. I would like to have it tested a bit before sending it to submissions. Attached are the changes to OSG's Camera and RenderStage. Camera got a new method called

[osg-users] Multiple render targets

2007-09-14 Thread John Donovan
Hi, is there anything else I need to do to render to two textures with the same fragment shader? I have the following code: cam-setRenderTargetImplementation(Camera::FRAME_BUFFER_OBJECT); cam-attach(Camera::COLOR_BUFFER0, _texture.get()); cam-attach(Camera::COLOR_BUFFER1,

Re: [osg-users] Multiple render targets

2007-09-14 Thread J.P. Delport
Hi, as far as I know its not supported in current version of OSG, there is no call to glDrawBuffers (as opposed to glDrawBuffer) which is needed for MRT. I have a version of RenderStage.cpp that I modified to allow MRT for one of our projects, but its a hack and I still need to properly

Re: [osg-users] Multiple render targets

2007-09-14 Thread John Donovan
Ah! That'd explain it :) Thanks JP. It would be handy to have a look at what you've done; perhaps we can both faff about with it to make it submittable. -J J.P. Delport wrote: Hi, as far as I know its not supported in current version of OSG, there is no call to glDrawBuffers (as opposed to

Re: [osg-users] Multiple render targets

2007-09-14 Thread John Donovan
J.P. Delport wrote: Hi, OK, here goes. Thanks JP, that worked a treat! We need some mechanism to store/assign more than one drawbuffer inside camera and possibly a flag to indicate we want MRT. RenderStage can then inherit/query these values to properly call glDrawBuffer(s). Yeah, I can

Re: [osg-users] Multiple render targets

2007-09-14 Thread Robert Osfield
On 9/14/07, John Donovan [EMAIL PROTECTED] wrote: Robert, do you have any plans for doing MRT stuff, or are you happy with JP and me to come up with something workable and submit it? The changes JP has made are fairly trivial, so it wouldn't take much to make it more robust. Send me a patch