Textures have blue tint suddenly in Ubuntu after update, no java/jogl change

After an update in Ubuntu (Karmic) suddenly all my apps that use JOGL have a blue tint.
I know this isn’t strictly a java question, but it’s seriously hampering my game development.

On the ubuntu forums there’s a hint that people see this with Totem video player, but I don’t get that.
It’s only with my opengl apps, even the older ones where I haven’t changed the code or libraries for years.

Anyone else had this experience and know of a fix? I’ve tried reinstalling the Nvidia drivers, that changes nothing. I’ve also tried grabbing the latest Nvidia drivers from their site but that doesn’t fix it either.

Thanks in advance for anyone that finds a fix - I’m sick of everyone looking like a blue smurf!
:slight_smile:

Aha! http://www.java-gaming.org/index.php/topic,22305.0.html
This pointed me in the right direction.

There was an update to Java in that Ubuntu update.

a quick switch from:

glu.gluBuild2DMipmaps(target, GL.GL_RGB8, img.getWidth(), img.getHeight(), GL.GL_RGB, GL.GL_UNSIGNED_BYTE, dest);

to:

glu.gluBuild2DMipmaps(target, GL.GL_RGB8, img.getWidth(), img.getHeight(), GL.GL_BGR, GL.GL_UNSIGNED_BYTE, dest);

sorted this out.
(this code chunk applies to textures without alpha, that are mip-mapped)

Please keep in mind that if you hardcode it, like you did, it will work in 6u20 and have that blueish tint in all versions before 6u20. Simply look at my code in that thread you mentioned: copy your data to a new Image where you specifically set the byte-order. Otherwise you’ll always going to have issues like this (6u21, 6u22 might have changed it again…)

Yeah, that’s very true, cheers!