up vote 0 down vote favorite
share [g+] share [fb]

Quite often, especially in X11-related things (X resources, Roxterm themes, etc) I see colours specified as 48-bit numbers: #2e2e34343636, #cccc00000000 instead of the usual 24-bit #2e3436 and #cc0000. What are the extra bits used for?

link|improve this question

71% accept rate
feedback

2 Answers

I can't speak to X11's use of them, but generally: additional color values which cannot be produced at lesser bit depths and alpha channels.

link|improve this answer
feedback

From the examples you give they are not being used at all since the 24 bit value is simply being repeated (a bit like the practice of using only 3 hex characters to represent "websafe" colours so #c00 means the same as #cc0000 or 204,0,0, extended to #cccc00000000).

32-bit values would usually use the last byte for alpha channel (transparency). I guess it's possible that the 48-bit values are using 24-bit colours with an independent alpha per colour, but the examples you give don't support this.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.