Hi Robert,
On 3/21/2013 10:44 AM, Robert Osfield wrote:
Hi Judson,
On 21 March 2013 13:56, Judson Weissert <[email protected]> wrote:
Thank you for the information. Knowing that you got it to work in an
embedded (non-fullscreen) window w/ 3D acceleration enabled is helpful.
I should have posted my environment information in my previous posts:
- VirtualBox 4.2.10
- OSG 3.1.2 (dev release)
- ATI RadeonHD 5700 series with atiumdag 9.2.0.0 (Catalyst 12.10) driver
- Host Windows 7 64-bit
- Guest Windows 7 Ultimate N 64-bit
Thanks for the details, this give us and others that follow along
after a bit more information of where problems might exist.
I've looked into the code that sets up the OpenGL side to the VBO's
from osg::Geometry and the key part is in include/osg/State's
setVertexPoint(..) etc. methods. In these I don't see any check for
VBO's being supported and no checks with the BufferData method that
gets the GLBufferObject structures so the code in include/osg/State
just merries goes along assuming everything is fine and tries to use
the VBO's. When binding the VBO's the code in
src/osg/BufferObject.cpp will be check for the extension support which
will avoid a crash in this code but later on when applying the array
data via glVertexPointer etc. calls it'll assume success and pass a
relative pointer rather than an absolute pointer which will result in
the crash you are seeing.
Ah, in hind sight (after staring at the code for hours) this makes a lot
of sense.
I haven't yet decided where abouts the best fix would be. Either a
variable in osg::State for whether VBO's are supported or a check in
BufferData::getOrCreateGLBufferObject. Currently my preference is to
put a variable in osg::State. There are other variables in osg::State
that are used for enabling/disabling OpenGL features so there is prior
art that could be used as template for this.
It looks like osg::State already has that flag. See
osg::State::_isVertexBufferObjectSupportResolved, and
osg::State::isVertexBufferObjectSupported. Perhaps just the guard is
missing?
Thank you for looking into this. My OpenGL/OSG debugging skills are not
quite where they need to be yet.
Regards,
Judson
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org