Palette Interference

General FreeBASIC programming questions.
Ophelius
Posts: 428
Joined: Feb 26, 2006 1:57

Palette Interference

Postby Ophelius » Apr 13, 2010 18:51

My game runs in 8-bit and I never make any calls to edit or alter the palette at any time, but sometimes I hear some brief disk reads and then my palette has some colors that are changed, mostly slots 0 to 7 and 250-255. I think Windows is doing this, so how can I prevent this? I'm not using all 256 slots, so I could just redraw my art so it doesn't use color slots 0-15 and 240-255 just to be safe, but damn! I'm using the Allegro lib.
1000101
Posts: 2556
Joined: Jun 13, 2005 23:14
Location: SK, Canada

Postby 1000101 » Apr 13, 2010 23:53

Those colour changes would most definitely be windows. It reserves certain areas of indexed colour modes for it's own purposes. If any indexed colour mode program loses focus you can expect it's palette to change while the other task has the focus.
Ophelius
Posts: 428
Joined: Feb 26, 2006 1:57

Postby Ophelius » Apr 14, 2010 0:29

I think it was my Auto wallpaper changer running in the background. Every 10 minutes it would change the desktop wallpaper, so I think it would access the palette. I turned it off and it seems to have stopped. Once it changed the Entire palette, so moving my colors away from 0-15 and 240-255 won't prevent it. I think this only occurs if I run my app in fullscreen.

Return to “General”

Who is online

Users browsing this forum: No registered users and 7 guests