See if you can figure this out

1 view
Skip to first unread message

Jason C.

unread,
Jul 18, 2010, 5:47:41 PM7/18/10
to Eternity Firmware
How does 00 F8 C0 07 1F 00 == red pixel, Green pixel, blue pixel in
RC2

Yet in a BMP a formats RGB like this (1 pixel of each color is shown
here)

FF 00 00 00 00 FF 00 FF 00

Thats the same color, But how does that make sense....

Jason C.

unread,
Jul 18, 2010, 6:04:41 PM7/18/10
to Eternity Firmware
I got it!

The samsung eternity displays 5bits per pixel. Each pixel takes up 2
byes (16 bits)

Of this 16 bit number we have
Bits 0 - 4 - Blue
Bit 5 - Unused
Bits 6 - 10 Green
Bits 11-15 Red
So each color has a maximum intensity of 1F (or 31 in case your
wondering :P

So
Red = ((int16)(((double)(RVal / 255.0)) * 31)) << 11
Green = ((int16)(((double)(RVal / 255.0)) * 31)) << 6
Blue = ((int16)((double)BVal / 255.0))

int16 pixel = Red | Green | Blue

Jason C.

unread,
Jul 18, 2010, 8:31:47 PM7/18/10
to Eternity Firmware
It should be noted that this is NOT true 16BPP, Its actually 15BPP.
16BPP would use the extra bit to give green a larger range (because
its the color our eyes see best).

Weird formatting too, I don't know any standard that is this exact
format. My guess is this is samsung specific.
Reply all
Reply to author
Forward
0 new messages