PDA

View Full Version : OpenGL seems to be getting its colour from the wrong array on some machines



radu242
08-01-2014, 12:18 PM
I have a OpenSceneGraph application which displays a 2D mesh and allows the user to make selections on triangles and vertices and colour them. If you aren't familiar with OpenSceneGraph, it's basiclly a scene graph library that uses OpenGL (the problem seems to be related to the low-level OpenGL rather than this library). Here is what the program looks like: i.imgur.com/TLa1Axx.png.

The bright red and green colours are colours assigned to those triangles, and the middle colour is the colour that highlights selected triangles. The relevant parts of the drawing are as follows:


The mesh is drawn using display lists.
The "colourer", which permanently displays colours, is drawn using VBOs.
The "selector", which highlights what is selected, is drawn using VBOs.


On my computer, this works fine. However, on a colleague's computer, both the colourer and selector are displayed with the selectors colours. In this screenshot, all the coloured parts of it would all be the middle colour. I've tried to print out the colour array as its drawing, but it seems to be holding the correct information on my (working) machine, and on the incorrectly-displaying machine. I'm not sure what other steps I can take to try and troubleshoot this. Has anybody run into anything like this?

If it helps, this (pastebin.com/tpZa3NHL) is the glxinfo of the machine that displays incorrectly, and this (pastebin.com/2cc9w19g) is mine.