Hi Chris,

The present version of PixelBufferObject only supports copying from
main memory to GPU, not back.  For the recent osgscreencapture example
use PBO's but I had to implement the PBO setup myself since the core
osg::PixelBufferObject didn't support it.  I haven't had a chance to
refactor osg::PixelBufferObject to include unpack/pack functionality,
but I do plan this for the longer term.

Right now you're best route is to just implement the PBO support
yourself, see the osgscreencapture example, in 2.5.1/SVN, for a guide,
note that for performance you'll need to double buffer and use RGBA
frame buffer formats.

Robert.

On Thu, Jun 5, 2008 at 4:39 PM, Chris Best <[EMAIL PROTECTED]> wrote:
> Quick question... Based on digging through the source, it seems all
> PixelBufferObjects are currently automatically set to
> GL_PIXEL_UNPACK_BUFFER_ARB by default and there's no way to change this to
> GL_PIXEL_PACK_BUFFER_ARB, correct? Meaning they can only be used for writing
> to the framebuffer, not reading from it? The application I'm writing is
> going to do a lot of reading colors back from a FBO as part of a
> pre-processing step, and based on my limited understanding reading pixels to
> a PBO is supposed to be significantly faster...
>
> Since it's a pre-processing step, speed isn't of utmost importance, but
> later on this step may end up being run relatively often (~1-5Hz or so), so
> should I try and take the time to extend osg::Image and
> osg::PixelBufferObject to support PACK operations or am I worried over
> nothing? :)
>
> -Chris B
>
> _______________________________________________
> 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

Reply via email to