Self Growth
Home > Memory > How much memory is needed to store a black and white photo with resolution 1024×512 if we use 32 gray levels?

How much memory is needed to store a black and white photo with resolution 1024×512 if we use 32 gray levels?

  1. Robin G
    November 7th, 2009 at 14:20 | #1

    256k

  2. Ted DeadMan
    November 7th, 2009 at 14:41 | #2

    There are several answers to this question depending on what you are doing:

    With no compression (like a bitmap):

    1024 x 512 x 8 bits = 410 k or so, I assume a few bits for brightness

    If you use compression then it depends on the type and agressiveness and whether it is lossy. Wild guess at a typical JPEG would be 40 k, really depends on complexity of picture and how much lossy you can tolerate

  3. billrussell42
    November 7th, 2009 at 15:12 | #3

    32 gray levels takes 5 bits.
    5 bits x 1024 x 512 = 2621440 bits
    2621440 bits / 8 = 327680 bytes

    in real life you would use a byte per pixel and waste the 3 bits, so then that is 1024 x 512 bytes or 524288 bytes.

    .

  1. No trackbacks yet.
You must be logged in to post a comment.

Powered by WP Robot