[osg-users] Problem blending multiple render passes

antiro black antiro42 at gmail.com
Sat Sep 9 05:42:39 PDT 2017


Hi,

1. I enabled blending on the root node of the subtree containing the camera's, I'm assuming this is carried over to the camera nodes.

2. I am using deferred rendering, all lighting calculations are based on the information in the GBuffer. I tried to get it to work with one camera and a subtree containing the lightvolumes with uniforms set per volume. However I couldn't get that to work, hence I thought I'd first try the simpler approach without writing to the stencil buffer.

3. I get that it is hard to help without example code and I am really grateful that you are trying anyways! The problem is that I have a pretty advanced rendering engine written in pure openGL. I decided that I wanted to port this to use OSG for improved cross platform compatibility (slowly starting to regret that decision...). This means that I'm working in a project of ~20k lines of code, which makes it really hard to isolate things into minimal examples. I never expected it to be this hard to restructure the project to work with OSG. The previous code is rather straight forward / low level: first run this shader, then run than shader etc. Now everything is attached to nodes in the scene graph and it is harder to for me wrap my head around the order things are happening in and how the openGL state is modified. If I ever get to the end of this, I might write a tutorial on porting pure openGL code to OSG. It will be the tutorial I wish I had right now :P

Thank you!

Cheers,
antiro

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







More information about the osg-users mailing list