Re: Quality factor and bits per pixel in JPEG




"fulltime" <PiaoChieh@xxxxxxxxx> wrote in message
news:1174669310.345962.236960@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi all,

I have an grayscale image 512 by 512 pixels = 262144bytes. I need to
encode this raw grayscale image into JPEG n find its PSNR at various
bpp. However, I do not quite get the definition of bits per pixel

Bits per pixel is just the file size (in bits) divided by the number of
pixels
(but I suspect you already knew that).

and its relationship with quality factor.

It depends on the complexity of the original image.
Quality factor just indicates the severity of the quantization.
For a given quality factor the file size will vary enormously,
depending on the original image complexity.

how do i calculate the quality factor in the quantisation matrix that
is needed to achieve a 0.25 bits per pixel and 0.5 bits per pixel
output?

You really just need to do it iteratively.
If you're doing this on many images you could plot a curve
of file size versus quality factor for a variety of images, and use that
to get you close to the final value based on the file size that
results from an initial quality factor. Otherwise, just try it with
various quality factors to get the file size you need.


.



Relevant Pages

  • Re: JPG compression question
    ... I don't know the (pixel) size of files from your camera, but would guess them to be about 2000 x 3000 pixels, giving about 6 megapixels. ... Depending on whether your shots are landscape or portrait, you should resize them (use the highest quality algorithm your program offers) so they fit on the screen. ... Use the highest quality you can to get the file size you need to get to, after you've resized the pixel dimensions, per your intended use. ... However, be aware that in any case, you cannot significantly reduce a file size by only cutting jpg quality without resizing it smaller first. ...
    (rec.photo.digital.slr-systems)
  • Re: Why is the pixel count growing so slowly?
    ... sensor, due to noise issues. ... even today's pixel count is resulting in lower ... quality images than before. ...
    (rec.photo.digital)
  • Re: Fuzzy Still Pictures
    ... Quality Video ". ... of argument, assuming a change of pixel aspect ratio, would this not be done ... not shown any evidence of DV-AVI non-square pixel specification. ... Al Stu - MVP ...
    (microsoft.public.windowsxp.moviemaker)
  • Re: Which internet labs print at what dpi?
    ... The appropriate term should be image PPI but generally confused with DPI, ... pixel dimension your image has that decide the quality. ...
    (rec.photo.digital)
  • Re: Fuzzy Still Pictures
    ... test of the original theory would be to get the filter removed from DV-AVI ... > Video " is due to the blurring filter. ... > However this does not disprove the existence of a quality degradation due ... > to non-square pixel adjustment.... ...
    (microsoft.public.windowsxp.moviemaker)