Inverted color

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Glawe
Posts: 11
Joined: Tue May 02, 2006 9:22 am
Location: Lund / Sweden
Contact:

Inverted color

Post by Glawe »

Hello all,

I have a strange problem. I have some code rendering a few textures to the screen in 2d. The source builds and run fine on windows. When i build and run it on my mac i get inverted colors on everything. Red becomes green, green becomes blue and blue becomes black... its really strage and im scratching my head to see if im missing something. Ive also tried to load diffrent fileformats but its the same prob with everything on the mac. (Oh, when rendering diffrens SColor in beginScene its the same thing). Ive tried to find something on the forums but didnt find anything. Anyone who knows whats wrong ? :)

(Im running in OPENGL. Software and Software2 wont render anything at all)

Br.
Fredrik
Glawe
Posts: 11
Joined: Tue May 02, 2006 9:22 am
Location: Lund / Sweden
Contact:

Post by Glawe »

To get you a better idea of how it looks, heres a couple of screenshots:

http://mail.glawe.se/mac.png

http://mail.glawe.se/pc.png

(yupp, its the same source and images, the only diff is mac running irr 0.14 and the pc irr 1.0.

/Fredrik
Last edited by Glawe on Sun May 28, 2006 9:42 am, edited 1 time in total.
Baal Cadar
Posts: 377
Joined: Fri Oct 28, 2005 10:28 am
Contact:

Post by Baal Cadar »

If I had to guess, I'd say, it is an endianess issue. I don't know how Irrlicht handles endianess, or if it does at all.
No offense :)
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Irrlicht has code for endianess swapping, so these should work. But maybe 2d drawing code is missing something? Did you check the 3d mesh parts in irrlicht already, because these should all work correctly.
Glawe
Posts: 11
Joined: Tue May 02, 2006 9:22 am
Location: Lund / Sweden
Contact:

Post by Glawe »

Nop, not yet, ill make a quick test tomorrow and see if that has the same problems.
Glawe
Posts: 11
Joined: Tue May 02, 2006 9:22 am
Location: Lund / Sweden
Contact:

Post by Glawe »

Just tried it out with a 3d mesh and the textures on works fine there, so it seems its only when rendering 2d textures it get messed up.
Post Reply