Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parsing numeric color into rgb values
Message
From
19/02/1998 19:58:57
 
 
To
19/02/1998 19:06:56
Christopher Holtz
Integral Computer Services, Inc.
Rochester, New York, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00079984
Message ID:
00079990
Views:
36
r= bitand(rgb(255,0,0),x)
g= Bitrshift(bitand(rgb(0,255,0),x),8)
b= Bitrshift(bitand(rgb(0,0,255),x),16)

...where x is your number.

Bit functions are so cool.

>I'd like to take a color numeric value, such as 15122532 and parse it into its separate rgb values.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform