Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debug build GL3 OpenGL error when braking #58

Closed
logzero opened this issue Nov 10, 2011 · 3 comments
Closed

Debug build GL3 OpenGL error when braking #58

logzero opened this issue Nov 10, 2011 · 3 comments
Labels

Comments

@logzero
Copy link
Member

logzero commented Nov 10, 2011

Win7x64/VS2010 debug build. Car XS, track paulricard88.

Game will abort when hitting the brakes, must be triggered by brake lights code.

INFO: GL Renderer: ATI Radeon HD 4800 Series
INFO: GL Vendor: ATI Technologies Inc.
INFO: GL Version: 3.3.11079 Compatibility Profile Context
INFO: Initialized GLEW 1.5.7
INFO: Loading data/shaders/gl3/vdrift1.rhr...
INFO: Loaded data/shaders/gl3/vdrift1.rhr
INFO: GL3 initialization successful
...
ERROR: OpenGL error "Invalid operation." during: void __thiscall GLWrapper::drawGeometry(unsigned int,unsigned int):f:\vdrift\vdrift\src\gl3v\glwrapper.cpp:152

backtrace:
vdrift.exe!GLWrapper::checkForOpenGLErrors(const char * function, const char * file, int line) Line 654 + 0x20 Bytes C++
vdrift.exe!GLWrapper::drawGeometry(unsigned int vao, unsigned int elementCount) Line 153 C++
vdrift.exe!RenderModelExternal::draw(GLWrapper & gl) Line 41 C++
vdrift.exe!RenderModelExternalDrawable::draw(GLWrapper & gl) Line 11 + 0xc Bytes C++
vdrift.exe!RenderPass::render(GLWrapper & gl, unsigned int w, unsigned int h, StringIdMap & stringMap, const std::vector<std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > const *,std::allocator<std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > const *> > & externalModels, const std::tr1::unordered_map<StringId,RenderTextureEntry,StringId::hash,std::equal_to,std::allocator<std::pair<StringId const ,RenderTextureEntry> > > & sharedTextures, std::basic_ostream<char,std::char_traits > & errorOutput) Line 506 + 0x19 Bytes C++
vdrift.exe!Renderer::render(unsigned int w, unsigned int h, StringIdMap & stringMap, const std::map<StringId,std::map<StringId,std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > *,std::less,std::allocator<std::pair<StringId const ,std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > *> > >,std::less,std::allocator<std::pair<StringId const ,std::map<StringId,std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > *,std::less,std::allocator<std::pair<StringId const ,std::vector<RenderModelExternal *,std::allocator<RenderModelExternal *> > *> > > > > > & externalModels, std::basic_ostream<char,std::char_traits > & errorOutput) Line 159 + 0x30 Bytes C++
vdrift.exe!GRAPHICS_GL3V::DrawScene(std::basic_ostream<char,std::char_traits > & error_output) Line 546 C++
vdrift.exe!GAME::BeginDraw() Line 685 + 0x22 Bytes C++
vdrift.exe!GAME::MainLoop() Line 717 C++

@antoniovazquezblanco
Copy link
Contributor

Also happened to me under Ubuntu just after loading the track before I could play.

@joevenzon
Copy link
Member

I just pushed a change to the git repo to disable asserts for these types of simple OpenGL errors. I had those enabled when I was writing the renderer and forgot to turn them off. I will look into the cause because this still needs to be fixed, but at least it won't crash.

@joevenzon
Copy link
Member

Fixed the real issue. The problem was just that the model wasn't being referenced if it was loaded via the content manager's cache, so it was getting deleted during the post-load sweep.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants