Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Baffling bug with dbPoint() and RGB values

Author
Message
Unkelben
20
Years of Service
User Offline
Joined: 2nd Feb 2004
Location: Montréal, Canada
Posted: 16th Dec 2006 00:08
I sample a pixel with dbPoint to a DWORD, then I clean it to keep the color data :

couleur = couleur&0x00ffffff;

On all tested machines (many! This code has been there for almost two years!), this works.

But I have one customer on whose machine the pixels aren't the same color! Here's an example, A being normal, B being him...

A:111111110000000000000000
B:111111101111111000000000

A:000000001111111111111111
B:000000001111111011111110

It seems the last bit of some bytes have problems. Does that mean anything to anyone?!

Jonathan
APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 16th Dec 2006 04:39
If he's running in 16bit mode, rather than 32bit mode, will the value vary? I'm not sure if dbPoint acts on a perpixel or direct memory access. You could try performing the test on your system for both 32bit and 16bit video modes to see if the colour information varies.

Paul.

Unkelben
20
Years of Service
User Offline
Joined: 2nd Feb 2004
Location: Montréal, Canada
Posted: 16th Dec 2006 18:18
No variation in 16bits. Anyways, the display is set to 32 bits in the game...

Jonathan
APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 16th Dec 2006 19:07
Hmm, that is odd.

EddieB
20
Years of Service
User Offline
Joined: 29th Sep 2004
Location: United Kingdom
Posted: 16th Dec 2006 23:05
High endian and low endian possibly?
Unkelben
20
Years of Service
User Offline
Joined: 2nd Feb 2004
Location: Montréal, Canada
Posted: 19th Dec 2006 18:25
Good idea, but not that either!

Jonathan
Argon Knight
22
Years of Service
User Offline
Joined: 29th Aug 2002
Location: Gastonia, NC, USA
Posted: 20th Dec 2006 05:24
oh, classic Obi Wan.
Unkelben
20
Years of Service
User Offline
Joined: 2nd Feb 2004
Location: Montréal, Canada
Posted: 21st Dec 2006 16:00
I don't get the Obi Wan reference...

Jonathan

Login to post a reply

Server time is: 2024-11-19 10:46:36
Your offset time is: 2024-11-19 10:46:36