Question:

Number of bits to represent three colors?

by  |  earlier

0 LIKES UnLike

Can somebody explain why are 24 bits needed to represent RGB colour? Isn't RGB just 3 colours? Hence, 2^2=4 colors.

That is, we only need 2 bits!

 Tags:

   Report

1 ANSWERS


  1. RGB (red, green, blue) are the primary colors of light that when mixed together form every other color (24 bits = total possible 16,777,216 combinations).

    The 24 bits are split into 3, 8-bit chunks and are used to describe how much of each RGB color should be used.  Mixing them yields almost every color you could want to use .  Some examples -

    Red    11111111 (255)

    Green 00000000 (0)

    Blue   00000000 (0)

    Gives you RED

    Red    00000000 (0)

    Green 11111111 (255)

    Blue   00000000 (0)

    Gives you GREEN

    Red    00000000 (0)

    Green 00000000 (0)

    Blue   11111111 (255)

    Gives you BLUE

    Red    11111111 (255)

    Blue   00000000 (0)

    Green 11111111 (0)

    Gives you YELLOW

    Red    11111111 (255)

    Green 01111111 (127)

    Blue   00000000 (0)

    Gives you ORANGE

    Red    00000000 (0)

    Green 00000000 (0)

    Blue   00000000 (0)

    Gives you BLACK

    Red    11111111 (255)

    Green 11111111 (255)

    Blue   11111111 (255)

    Gives you WHITE

    Check out the links for more explanation and examples of colors and their RGB values.

    NOTE - Red, YELLOW, Blue are the primary colors of ink/paint that are used to make all colors.

Question Stats

Latest activity: earlier.
This question has 1 answers.

BECOME A GUIDE

Share your knowledge and help people by answering questions.