Thanks J.P. You say that I can call myim->dirty() or myim->setImage(), but wouldn't calling myim->setImage() cause a slow update? That's what I seem to be experiencing. I need to update based on the sensor around 30Hz.
The imagery data (from sensor) is in system memory ... just trying to get a view that shows it without dropping so many frames. Thanks again, Ben On Fri, Feb 26, 2010 at 12:23 AM, J.P. Delport <jpdelp...@csir.co.za> wrote: > Hi Ben, > > we also pump data from cameras into the GPU. To enable PBOs is simple: > > // make image > osg::ref_ptr<osg::Image> myim = new osg::Image(); > // attach pbo > myim->setPixelBufferObject(new osg::PixelBufferObject(myim.get())); > > // point im to data, avoid copying (mod format here for your app) > myim->setImage(ImageFormat_[i].getWidth(), > > ImageFormat_[i].getHeight(), > 1, 1, GL_LUMINANCE, > GL_UNSIGNED_BYTE, > my_data_pointer, > > osg::Image::NO_DELETE); > > // assign to texture > mytexture->setImage(myim.get()); > > Now, when the data update, just call myim->dirty() and all should update. > You can also call setImage again. > _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org