megapixels


BMurray

Link Posted 23/04/2013 - 06:41
Does anyone have an idiots guide to megapixels? i know i probably dont need to know too much about them but there are a couple of things which confuse me, one being that if i have pentax k-30 with 16 megapixels how can i produce photographs which are 20 and above? and if i have a shot which is 18-20 megapixels but i crop it down to a small area which then becomes 971kb is that 971kb proportionate to the overall quality of the larger image or do i lose quality?
just curious.
B Murray

dougf8

Link Posted 23/04/2013 - 09:00
jpeg files do not store all the information available. areas of the same or similar light are stored in a kind of shorthand. Colours and shades can be dithered out of the image. If you try to recreate what the sensor saw from the jpeg file you will fail, some data is discarded. The file size is a fraction of the raw size.

So a jpeg of an even blue sky will be much smaller than a jpeg of a complicated landscape or one interesting textures.

If the images are held in a lossless format such as tiff or bmp, each pixel on the sensor is registered in the file and each file will be the same size.

If you shoot raw the files will be similar, I'm not clear of there is some compression on raw files, if there is it is not lossless as each pixel can be retrieved from the file.

I shoot raw plus a small jpeg.

Cropping should not affect quality unless you keep saving as jpeg and overwriting the original
Lurking is shirking.!
Last Edited by dougf8 on 23/04/2013 - 09:02

BMurray

Link Posted 23/04/2013 - 09:12
i always shoot in RAW then save as a jpeg after processing but never overwrite the original RAW, would the file only be larger if i saved as tiff or bmp or will the quality be better as well?
B Murray

StephenHampshire

Link Posted 23/04/2013 - 09:29
BMurray wrote:
Does anyone have an idiots guide to megapixels? i know i probably dont need to know too much about them but there are a couple of things which confuse me, one being that if i have pentax k-30 with 16 megapixels how can i produce photographs which are 20 and above? and if i have a shot which is 18-20 megapixels but i crop it down to a small area which then becomes 971kb is that 971kb proportionate to the overall quality of the larger image or do i lose quality?
just curious.

As I understand it the sensor sizes are in pixels. Each pixel has 12 or 14 bits of information regarding it (12 on K30, K20 etc, 14 on K5) 8 bits to a byte so a RAW image should be of the order of 16000000 x 12 / 8 or 24Mb if every pixel has 12 bits of info. In practice files with lots of black spaces (black = no info) will be quite a bit smaller. My Raws tend to be 15-18Mb
Everything Changes
http://www.flickr.com/photos/arleimages/

dougf8

Link Posted 23/04/2013 - 09:29
It depends on your printer, projector, screen.

If your jpeg is the finished image then the loss is minimal. you can set the quality of a jpeg and also the compression method.

I'd bet at 100% quality and the best sampling method you wouldn't detect any loss. (I can't, but I'm no pro!)

But to store and allow the display/printer the best chance of showing everything you want then tiff/bmp pass all the information. screens and prints can't necessarily show all the information so your efforts may be wasted. or the next generation of display might show the hidden depths.

there are other issues like 12bit vs 14bit source images and PhotoShop saving as 8 or 16bit images.
Lurking is shirking.!

Jim-w

Link Posted 23/04/2013 - 09:31
Quote:
i have pentax k-30 with 16 megapixels how can i produce photographs which are 20 and above?

Is it poss that you are confusing megapixels with megabytes

Raw files are big, just had a quick look at some of mine and 16, 17, 18 and 19 plus MegaBytes normal, camera is a 16 odd MegaPixel K5

Converting to jpeg will reduce file size considerably and then cropping or changing image size will reduce file size even more down to the KB sizes you mention.

I hope this helps and am sure someone who understands all this technical stuff will come along and explain it better than I can.

All the best......Jim.

Mannesty

Link Posted 23/04/2013 - 09:55
It's not easy to determine image file sizes based on the sensor size.

Quite apart from the image itself, there's a lot of other information recorded about the camera settings, known as EXIF (EXtended InFormation).
Peter E Smith

My flickr Photostream
Last Edited by Mannesty on 23/04/2013 - 09:55

gwing

Link Posted 23/04/2013 - 10:23
OK I'll have a stab at explaining.

If your sensor is 16 megapixels you will have 16M (16*1024*1024)pixels in that sensor. The camera produces a raw image from this storing the sensors resolution in bits for each pixel, with typical sensors storing 12,14 or 16 bits per pixel.

Lets assume our camera has 16bit resolution to make the maths easier. 16 bits is two bytes and that is per pixel so for a 16 Mpixel*2byte sensor we get a resulting 32 megabyte(MB) image. That is a large image but when the camera saves it as a RAW file it applies lossless compression so that we still have 100% quality but our actual RAW file size is something like 12 to 20 MegaBytes. The more detail there is in the image the less compression can be achieved without losing quality and this accounts for different images having different file sizes.

As an alternative to saving RAW files we can choose to save JPEG files from our cameras. These still have the same raw image from the sensor but instead of lossless RAW file compression lossy JPEG compression is applied. This produces much smaller and more easily handled files, but image information (quality) is also lost - even at the best quality jpeg settings.

Whether you use JPEG or RAW files there is, in addition to the image, some labelling and descriptive information attached (known as EXIF data) but this is very small compared to the image so, in terms of file size, we can ignore it completely.

Lastly, if you crop an image, you don't lose any quality - your cropped section is just a small part of the original image and the same quality as the original. (strictly speaking this is only 100% true for RAW files, because of the lossy compression each time you open and resave a jpeg file you lose a little bit of quality, so opening a jpeg, cropping and resaving that crop will be just a little lower quality than the original - provided you use high quality jpeg options and don't do it too often it won't matter).
Last Edited by gwing on 23/04/2013 - 10:25

MrB

Link Posted 23/04/2013 - 11:00
BMurray wrote:

and if I have a shot which is 18-20 megapixels but i crop it down to a small area which then becomes 971kb is that 971kb proportionate to the overall quality of the larger image or do I lose quality?
just curious.

Whether by "crop" you mean that you are cutting out part of the image, or you mean that you are reducing the pixel dimensions of the whole image (i.e. making it smaller), the effect will be similar. Here is an analogy (ignoring, for simplicity, the effects of screen, printer and processing).

Just as one might cut out part of a picture from the page of a magazine, the quality you see depends on how it is viewed. When you simply look at the cut out piece from the magazine, then it will have the same quality as the rest of the page, but if you look at that same piece through a magnifying glass, then the quality seems poor.

Similarly, if you crop a small area of a digital image (or make the whole image much smaller), and then expand the result to fill the screen (or print at e.g. A4 size) its quality will look inferior to the original image viewed at the same size.

Philip

(Apologies if this response is too simplistic, or if it falls short of the technical expertise of experienced photographers.)

Gamka

Link Posted 23/04/2013 - 11:02
gwing wrote:
OK I'll have a stab at explaining.

If your sensor is 16 megapixels you will have 16M (16*1024*1024)pixels in that sensor. The camera produces a raw image from this storing the sensors resolution in bits for each pixel, with typical sensors storing 12,14 or 16 bits per pixel.

Bits per pixel?

Surely it is Bits per Channel -12, 14 or 16 with 3 channels per pixel.

cabstar

Link Posted 23/04/2013 - 11:45
Megapixel sizes are simply the sensor size x x y for example 12 megapixel would be 4000 x 3000 pixels sensor size.

As for file size that totally depends on what is in your photo and bit size.
PPG Wedding photography Flickr
Concert photography

Currently on a Pentax hiatus until an FF Pentax is released

Whizzkiddwill

Link Posted 23/04/2013 - 13:05
Have a look here, theres load of info on lots of different things.

link

Will
Pentax K-x, DAL f3.5-5.6 18-55mm,Pentax-A 50mm f2, DAL f4-5.6 50-200mm, FG360FGZ

gwing

Link Posted 23/04/2013 - 14:05
Gamka wrote:
gwing wrote:
OK I'll have a stab at explaining.

If your sensor is 16 megapixels you will have 16M (16*1024*1024)pixels in that sensor. The camera produces a raw image from this storing the sensors resolution in bits for each pixel, with typical sensors storing 12,14 or 16 bits per pixel.

Bits per pixel?

Surely it is Bits per Channel -12, 14 or 16 with 3 channels per pixel.

Not really. The sensor only records a single luminance value for each pixel i.e. it really is something like 16 bits per pixel in the sensor and raw image. Later on that pixel information gets de-mosaiced and each pixel infers colour information from its neighbours to obtain the so called three colour channels per pixel. If you dump the raw image to a demosaiced uncompressed tiff file it will indeed take 16MP*2bytes*3channels=96MB - which is a very large file indeed.

For fairly obvious reasons we don't generally produce files like that. What we do is either use the raw files which are not demosaiced and hence don't have the x3 multiplier or we use jpegs, which are demosaiced and hence multiplied by three channels but are also very substantially compressed to reduce the size further.
Add a Comment
You must be registered or logged-in to comment.