Hi Robert,

Thanks a lot for the quick response. I have solved this problem with your
help.

I do with this following call,

     Producer::RenderSurface::*shareAllGLContexts*(true);

But, this time, when I create more than one VBO,

float* cachedData =
static_cast<float*>(mExtension->glMapBuffer(GL_ARRAY_BUFFER_ARB,GL_READ_WRITE_ARB));

function always returns NULL and I can't map GPU buffer. But it works for
one VBO for multiple window.


On Sun, Mar 16, 2008 at 6:42 PM, Robert Osfield <[EMAIL PROTECTED]>
wrote:

> Hi Selman,
>
> This is the way that OpenGL objects work - they aren't by default
> shared between separate graphics context.  You'll either need to
> maintain separate VBO's for each context or share graphics contexts.
>
> There is a lot of support in the OSG for managing separate objects
> across multiple graphics contexts so is you use classes like
> osg::Geometry it'll manage this all for you.
>
> Robert.
>
> On Sun, Mar 16, 2008 at 4:11 PM, selman duatepe <[EMAIL PROTECTED]>
> wrote:
> > Hi everyone,
> >
> > I have implemented Terrain library using Geometry Clipmap algorithm. In
> my
> > project, I have to display terrain two different windows. And, I have
> used
> > vertex buffer object to render the terrain. When I use to second
> display,
> >
> > float* cachedData =
> >
> static_cast<float*>(mExtension->glMapBuffer(GL_ARRAY_BUFFER_ARB,GL_READ_WRITE_ARB));
> >
> > function always returns NULL and I can't map GPU buffer. But it works
> for
> > one window.
> >
> >  Anyone idea about this problem.
> >
> > Thanks a lot.
> >
> > _______________________________________________
> >  osg-users mailing list
> >  [email protected]
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >
> >
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to