Closed pahansen95 closed 7 years ago
Hi @CommodoreCrunch99
Those index values inside of r.pending.queries
are arbitrary numbers (like pointers) generated by OpenGL at runtime, so they aren't super useful for figuring out what went wrong here. Can you find a minimal program that reproduces the issue? That'd be the best place for me to start on figuring out what causes this.
Please see this github repo
https://github.com/CommodoreCrunch99/IssueExample
It is the code I am using stripped of everything referencing packages from another project I made.
Thanks!
I've found out that commenting out all of your OcclusionTest = true
lines in mainWindow.go
temporarily works around the issue (although this obviously disables occlusion testing).
Hi @CommodoreCrunch99 I found the cause was a simple bug where we incorrectly assumed the index was correct while removing things from the slice. Basically, the slice length would change when we removed the first element, so the second removal would result in the 'slice bounds out of range' panic seen here. I've fixed in https://github.com/azul3d/engine/commit/eb48fbeb6d97ddebb823269e5cf41ae0af903765 and your example seems to work now.
I am getting an index out of range panic
I altered the code to print out the values for r.pending.queries and query index and this is what i saw (respectively)