PDA

View Full Version : vbo and glBindBuffer crash



ale211734
04-22-2015, 01:12 AM
Hello,

I need help...

I get a very strange and complex problem with vbo.
I get a crash at runtime on glBindBuffer call in the rendering function for the 3d object.

I get a different behaviour if my object is allocated inside my dll plugin (my program in this case crash on rendering function on glBindBuffer) while my program run correctly when I allocate my object outside
the plugin (dll), in the application code (.exe). I use the same function to inizialize vbo and render vbo.

I use qt and opengl. My dll are qt plugins.
I noticed different stack call when object is allocated inside or outside my plugin.


this is the stack call that debugger show me when the object is instanced inside plugin (in this case application crash!)



testPlugin.dll!vcg::GlTrimesh<CMeshO,0,std::vector<CFaceO *,std::allocator<CFaceO *> > >::DrawFill<1,1,0>() Line 477 C++
testPlugin.dll!vcg::GlTrimesh<CMeshO,0,std::vector<CFaceO *,std::allocator<CFaceO *> > >::Draw<6,1,0>() Line 433 C++
testPlugin.dll!vcg::GlTrimesh<CMeshO,0,std::vector<CFaceO *,std::allocator<CFaceO *> > >::Draw<6,1>(vcg::GLW::TextureMode tm=TMNone) Line 394 + 0x8 bytes C++
testPlugin.dll!vcg::GlTrimesh<CMeshO,0,std::vector<CFaceO *,std::allocator<CFaceO *> > >::Draw<6>(vcg::GLW::ColorMode cm=CMPerMesh, vcg::GLW::TextureMode tm=TMNone) Line 382 + 0xc bytes C++
testPlugin.dll!vcg::GlTrimesh<CMeshO,0,std::vector<CFaceO *,std::allocator<CFaceO *> > >::Draw(vcg::GLW::DrawMode dm=DMSmooth, vcg::GLW::ColorMode cm=CMPerMesh, vcg::GLW::TextureMode tm=TMNone) Line 370 + 0x10 bytes C++
testPlugin.dll!MeshModel::Render(vcg::GLW::DrawMod e _dm=DMSmooth, vcg::GLW::ColorMode _cm=CMPerMesh, vcg::GLW::TextureMode _tm=TMNone) Line 115 C++
testPlugin.dll!MeshNode::draw(const RenderMode & rmode={...}) Line 125 + 0x39 bytes C++
DentalCad.exe!GLArea::renderSceneGraph(RenderNode * root=0x05019768, bool filterTooths=false, const vcg::Color4<unsigned char> & colorPerMesh={...}) Line 591 C++
DentalCad.exe!GLArea::paintEvent(QPaintEvent * event=0x0041ca14) Line 400 C++


and this is my stack call when the program run correctly and the object is allocate outside the plugin



...
DentalCad.exe!MeshModel::Render(vcg::GLW::DrawMode _dm=DMSmooth, vcg::GLW::ColorMode _cm=CMPerMesh, vcg::GLW::TextureMode _tm=TMNone) Line 111 C++
DentalCad.exe!MeshNode::draw(const RenderMode & rmode={...}) Line 125 + 0x39 bytes C++
DentalCad.exe!GLArea::renderSceneGraph(RenderNode * root=0x0519b330, bool filterTooths=false, const vcg::Color4<unsigned char> & colorPerMesh={...}) Line 591 C++
DentalCad.exe!GLArea::paintEvent(QPaintEvent * event=0x0035cb4c) Line 400 C++


GLArea is my qt opengl component while MeshNode is a node of scenegraph that containts a draw function for my allocate 3d object


Thanks in advance.