Re: [osg-users] Easy blur effect with HUD Camera?

2014-04-03 Thread Petr Svoboda

Paul Martz wrote:
 If you're not picky about the blur quality, just render to a texture that is 
 1/16th the size of your screen (1/4 width x 1/4 height), then apply the 
 texture to a fullscreen quad with GL_LINEAR filtering. This can be 
 accomplished with OpenGL v1.0 functionality and should be fast and 
 well-supported on all graphics cards.
 
  --
 Post generated by Mail2Forum



Thank you, this is exactly what suits me.

Just one more question.
My post-rendered camera is then darker, like with 50% of light compare to 
original scene. Could it be somehow connected with using osgShadow::ShadowScene 
or the lightening problem is somewhere else?

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





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Easy blur effect with HUD Camera?

2014-04-02 Thread Sebastian Messerschmidt

Hi Petr,

You will have to render your scene to texture (RTT) and perform a 
shader-blur pass before displaying it in the viewer.
Look at the render to texture example and the shader examples. Finding a 
blur shader should be easy with most search websites, or in the osgPPU 
examples.


So effectively:

1. Render scene to Texture1
2. Run blur pass on Texture1 and display Result in Framebuffer or write 
to Texture2
3. If Framebuffer - draw hud above, else draw Fullscreen-Quad with 
Texture2 and draw HUD afterwards




This will also work on Intel cards with OpenGL 2.0 (i even think it is 
possible on 1.5)




Hi,

I would like to make something like menu using overlaying HUD Camera with 
background blurred.

Code:
http://rk.md/wp-content/uploads/2012/08/2012-08-18_4.jpg


- something like this but with sharp / focused scoreboard but everything 
else blurred

How to do it?


I tried osgmotionblur example with  these opengl hacks but the problem is that if I 
don't use dedicated GPU (Nvidia) and using integrated Intel GPU then there is no blur 
effect but many OpenGL errors.

So, Is there any easier method/hack to make the background blurry or 
blurry-like?

Pictures:
before

Code:
http://imgur.com/EII7vZG,IUz5wAa



after (using Photoshop Gaussian blur )

Code:
http://imgur.com/EII7vZG,IUz5wAa#1





  


Thank you!

Cheers,
Petr

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





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Easy blur effect with HUD Camera?

2014-04-02 Thread Paul Martz
If you're not picky about the blur quality, just render to a texture that
is 1/16th the size of your screen (1/4 width x 1/4 height), then apply the
texture to a fullscreen quad with GL_LINEAR filtering. This can be
accomplished with OpenGL v1.0 functionality and should be fast and
well-supported on all graphics cards.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org