If the frame buffer has 8 bits per pixel and 8 bits are allocated for each of the R, G, B components, what would be the size of the lookup table? a) 24 bytes b) 1024 bytes c) 768 bytes d) 256 bytes
I read about Framebuffer and what I understood is “It stores the color values (in case of color frame buffer) in indexed form. So if we have $8-bit$ color, then possible colors are $2^8$*So frame buffer would store color values for each pixel on screen and it’s size would depend on screen resolution. Corresponding actual color values (or codes) would be stored in lookup table” So, Lookup table would have $2^8 = 256$ entries, which is $256$ bytes, since each entry is of 8-bits = 1 byte. But that is not the correct answer to above question. So, can anyone tell, where am I going wrong ? Also, question says frame buffer has 8-bit per pixel and 8-bits are allocated for each RGB , This means for each pixel, frame buffer has $8,8,8,8$ bits allocated ?
Asked By : SimpleGuy
Answered By : Yuval Filmus
Best Answer from StackOverflow
Question Source : http://cs.stackexchange.com/questions/35711