Showing posts with label resolution. Show all posts
Showing posts with label resolution. Show all posts

Saturday, March 31, 2012

Does reducing JPG resolution decrease, increase, or have no effect on image quality?

Question

I'm getting ready to download a bunch of images from Dreamstime. I'll eventually want most of the images in the 400x300 pixel range for my website when I'm done working with them. Dreamstime offers various resolutions to download images in- 1000x750, 2000x1500, 4000x3000, etc. I'm used to printing, where you want to get the largest images possible because that translates into higher quality prints.

I've searched around on Google and Stack Exchange and I can't figure out the answer to this question: Is there a loss in quality if I choose the 4000x3000 images and reduce them to 400x300 in Photoshop? Is the quality loss greater or less than if I reduced the 1000x750 image to 400x300?

Thanks Stack Exchange!

Asked by Jack T

Answer

Bear with me for a second here for some background....

When you downsample a 4000×3000 image to 400×300, you are "discarding" 11.9 million of the 12 million pixels. This clearly reduces "image quality", depending on what exactly you mean by that term.

If you go from 1000×750 to 400×300, you're reducing the area by about 6 times. Again, data is discarded, but not as much.

Now, if your original image had a lot of defects — noise, aberrations, and focus error — the resolution may exceed the "effective image quality", and the extra detail is contributing nothing. In that case, downsampling to some degree doesn't "really" reduce image quality. This is very dependent on the actual original, though — and in any case, going all the way down to a basically-thumbnail-sized 400×300 is pretty drastic.

Hopefully that's all pretty obvious. With that out of the way... In this case, since 400×300 images are your target, the question is really "is there any value in having larger images and downsizing them myself rather than having the stock photo agency do it for me."

The answer to that is: maybe.

  1. It's possible that the agency uses poor downsampling and sharpening algorithms for the smaller choices. Or they may use perfectly good algorithms that have the wrong parameters for your taste — for example, too much sharpening. By picking a bigger version and downsampling yourself in Adobe Photoshop or dedicated scaling software, you might be able to do a better job, and tailor the results for your artistic needs and desires.

  2. Starting from bigger pixel dimensions allows you more flexibility, since you can crop and still have room left over. You could decide that just the corner or the center of an image fits your use better, and crop out a 400×300 section rather than downscaling.

  3. Likewise, if you're doing other manipulation on the image, to change color or make a montage from multiple images, having some extra data to work with at that stage won't hurt (although beware of spending too much time getting detail right when it's just going to get scaled out of perception in the end).

Ultimately, the answer will depend on your particular situation and how it relates to these factors, but hopefully this will give you a way to make that decision.

Answered by mattdm

Monday, March 26, 2012

What image dimensions are used for 500px?

Question

The name is 500px.com, but what is the image resolution for which to optimize before uploading your photos there?

Asked by Marius Butuc

Answer

From their relevant Support page: width 880px for photos in landscape orientation, height 900px for images in portrait orientation. Even when you submit your images in that size, they will still get resized for display in thumbnails, and on iOS devices. Oh, and your carefully prepared originals in correct size are still recompressed into smaller files.

The name is a leftover from early days of digital photography, when 500 pixels was a suitable size for longer edge of images distributed over slower-than-today connections and displayed on CRT monitors.

Answered by Imre

Tuesday, March 13, 2012

How large an image do I need to print a 32″ by 18″ poster at 300 DPI?

Question

I need to have an image printed as a poster at 300 DPI, but am unsure of how big the file must be. Also, what file format is best?

Asked by Jake223

Answer

The straightforward answer to your question is very simple arithmetic: 32×300 = 9600 and 18×300 = 5400, so 32 inches by 18 inches at 300 dots per inch is 9600 by 5400.

However, it gets a little more complicated when you consider a more complicated relationship between pixels and colored dots in your output medium. For details on this, take a look at jrista's answer to a similar question: What DPI should I resize my image to for best printing quality?, at What does DPI mean?, and at Is there a general formula for image size vs. print size?

It sounds like you're doing something specific, though. In that case, the best answer is to ask your print service what they recommend — and the same thing goes for file format (and color space, a whole 'nuther can of worms).

Answered by mattdm

Tuesday, March 6, 2012

How to find out the original size of a photo?

Question

Follow-up from What's the max size a photo can be enlarge based on size while preserving the same quality?

Answer

For a digital image, the size of the is always embedded in the metadata. This means that you can view the original size of an image in the original image.

If you have is a resized image, then the EXIF contains the new size and, unfortunately, the original size has been lost. The EXIF information may still contain the model of the camera which took the image though. This will let you find the maximum possible size of the original image, even though the camera may have been set to shoot at a lower resolution.

Answered by Itai

Friday, February 24, 2012

What are my options for an FX wide-angle prime to suit the D800's successor?

Question

I have a D700 which I'm not planning to replace at this point in Nikon's product cycle. I'll porbably buy the D800's successor. Not because I don't like the D800 (especially its usability improvements around focus mode switching and Live View, which don't seem to have attracted much attention) but because I can't justify the cost when there are too few things the D800 does that the D700 doesn't.

Anyway, although I'm keeping the D700 for now, I'm planning to buy a wide-angle prime so that I end up with this in my bag: D700, SB-800, 105mm micro, 50mm, wide-angle.

I need to choose a wide-angle lens. The 14-24 is a great lens, but too big for me to routinely carry it. So I'm going to buy a wide-angle prime. However, I don't want to buy a prime now that turns out to be disappointing on the replacement body I eventually buy.

As for focal length, the 35mm is a lens I could like but it's too close to the 50mm for me to seriously consider buying it. Hence I'm looking at the 20mm - 28mm focal length range. Which Nikon primes have sufficient micro-contrast to work well with bodies with a finer pixel pitch at full frame (I'm going to assume for the sake of the discussion that that is what the D800 successor will be like: FX, high resolution)?

I'm going to assume that the 24mm f/1.4 is going to be among the suggestions, and in fact Nikon points it out in the technical guide for the D800 as being suitable for use with the D800E. It's heavy and expensive so I worry that in practice I'd leave it behind with the 14-24. So I'm interested in my other likely options.

Budget is important for recommending the right choice. But I'm pretty flexible for a reason: new lenses will be launched between now and the launch of the D800's successor. So maybe the right approach is to buy something less expensive now and upgrade later to some not-yet-existing lens. The principle I'm going to operate on is that I'm OK with buying a lens now, that's actually not suitable for the D800's successor at up to €400. I'd just sell if that seems like the right thing to do, and not worry about losing some of its value on the re-sale. On the other hand, if I'm going to spend more than €500 I don't want to plan to replace the lens.

My planned uses are principally travel photography, interior shots, architecture, some environmental portraits.

What do you say?

Answer

My suggestion would be that you hold off on a wide prime if you're buying it for the future. Any of them are okay if you're looking to match them with the D700's sensor, but the D800 (and, one would assume, its successor models) has about the same pixel density on the sensor as the D7000, and the Nikkor full-frame wide angles are showing their age on that model (and not well, either). They're not particularly sharp at the corners, and display significant vignetting already -- and that doesn't account for performance at the edges of a full-frame sensor. If you can, try to get some feedback from people who've tried them on a D3X, but I wouldn't expect any rave reviews.

Since Nikon has decided to step into the miniature medium format world -- using a sensor that's verging on the very edge of even theoretically perfect lens performance -- and their stable of full-frame wide-angle primes is getting a little long in the tooth, I'd expect to see some newer design trickling in over the next few years. So buy for the short term rather than for the future if you're waiting for a successor to a model that isn't actually shipping yet -- something that might show its age on a D800 could be the best thing that ever happened to your D700. And get the focal length you need rather than worrying about which one is "best" -- the best lens is the one that lets you take the pictures you want to take, not the one with the best specs, build quality or handling.

Answered by Stan Rogers

Tuesday, February 14, 2012

Do compact and DSLR cameras have the same sensor size if they have the same number of megapixels?

Question

In the analog camera, I understood the impact of using a 35mm film vs using a 70 mm film.

However in digital world, I dont know if the sensor size is the same for compact and DSLRs. In other words, if I use a compact and DSLR both of 12 megapixels and, say, with a lens of 35mm, will there be any difference in terms of resolution of the image?

Asked by Dheer

Answer

Sensor area doesn't determine resolution in the same way as the film era. Back then simply increasing the area of film would yield a similar increase in the size you could print, and therefore the detail you captured. In the digital world sensors can have different numbers of pixels per cm

Both 12MP compact and DSLR will resolve similar levels of detail but the DSLR sensor will be about 5-6 times bigger in each dimension. The extra size tends to provide better low light abilities as well as shallower depth of field at the same f-stop. This is because at the same f-stop a small and large sensors receive the same light per unit area, however a larger sensor receives more light in total leading to a reduction in photon noise. The difference in depth of field is due to the need to use a longer focal length for the same field of view, giving a larger apparent aperture.

Important note:

Differences in light gathering ability, DOF are not absolute and depend on the actual lenses that are available. For example it is true that for a small sensor compact and DSLR with f/2.0 lenses the DSLR will gather more light and have shallower DOF, however if you compare a 35mm DSLR to a medium format camera (with larger sensor) you might find that f/2.0 lenses aren't available for the medium format, so the smaller sensor 35mm DSLR can gather more light and attain shallower depth of field due to the availability of fast lenses.

Second note:

Not all compacts have small sensors, some now have sensors the same size as most DSLRs, such as the Fuji x100, Sigma DP1, the new Canon G1X and the Sony NEX range, and some are in between - e.g. the micro 43rds and the Nikon 1 series.

Answered by Matt Grum

Thursday, January 5, 2012

What megapixel value is equivalent to which ISO film?

Question

Is there some kind of equivalency table or formula that expresses what kind of pixels you need in a digital camera to have roughly the same quality as a particular ISO graded film? What other variables would influence this (focal-length, exposure time, etc)?

Answer

I remember seeing a figure of 22MP was "as good" as 35mm resolution (of course, with film it isn't just the ISO, but the manufacturer and age of the film, skill of developer etc.)

Higher ISO film tended to have more grain; and higher ISO digital shots exhibit more noise - a similar cause, but the visual appearance is different.

Digital ISO noise is related to the size of each pixel, as the noise is per-pixel (so the more pixels you have, the less obvious noise is when viewed the same size). One analogy I've used in the past to demonstrate this is to ask several people to time with a stopwatch how long it takes a car to drive around a car park, and then to time how long a person takes to do the same journey - because the person is slower, the margin of error is a smaller in proportion to the overall figure, even though different people will give timings to within a few seconds of each other.

Wednesday, November 16, 2011

CSI image resolution enhance: How real is it?

Question

So I watched the following 1 minute long Youtube clip from CSI New York. In the clip, using what seems to be the recording from a standard bank camera, they zoom in at least 100, and see the image of the culprit in the reflection of the eye of the girl.

Now, I thought this was completely ridiculous, so much so that I thought it was actually really funny.

However, my friend argued that there are very good tricks for image enhancement, such as "super resolution" a procedure where multiple frames of a video to produce a much higher single resolution image. He did think the show bends the truth quite a bit, but how much?

Honestly, I don't actually know anything about these things, so my question is:

How good is modern image resolution enhancement? Also, how far off are the CSI television programs?

Thank you,

Remark: This is cross posted on the Skeptics site. I was told I might receive better answers here.

Answer

Short answer: you can obtain some very good results, but only under certain conditions and absolutely not even close to what is shown in the linked video clip.

My company, Amped Software, develops image and video processing software for forensic and intelligence applications, so basically we are the real world counterpart of the CSI software.

With reference to the general problem of quality enhancement, I can tell you that for our market it is a huge problem to live up to the expectations created by TV series and Hollywood movies. You can see on our samples page that sometimes the results we are able to get are really amazing, but it is important to understand that we can obtain them only under some conditions: if there is information that is covered by disturbs, but it is there, we are able to recover it. If there is no information, we can't and we must not recreate it. In this particular application is essential not only getting the results from a visual point of view, but also following a scientific workflow that must be accepted by the court.

Last year I presented a research describing issues and results on almost 200 cases I've worked on and the final result was the following:

  • in more than 50% of the cases there is nothing to do (for example recovering a license plate that is 5x2 pixels is completely impossible with any software on the world);
  • in about 30% of the cases we can get some little result (for example restoring some letter of a license plate or improve the overall appearance of a face);
  • in 10% of the cases you get good results (you get most of the license plate, for example).

Please note that all these cases had severe quality issues. If their quality was good, we weren't asked to work on them.

For what regards specifically resolution enhancement:

  • when you zoom on an image you are interpolating missing pixels: from a single image you can improve visually the appearance of the image but you will not add any real detail;
  • super resolution techniques may yield good results under certain conditions: you should have enough frames, shifted by a non integer amount of pixels and preferably with few compression artifacts. In the best case you can expect good results within 2x and 3x zoom.

What is shown in the video clip can be possible only if the original video has been shoot at several megapixels and then you will have the resolution to zoom very close (more or less like you do on Google Maps). Of course, at that point there still would be other problems, like the right focus, low light condition, the fact that the perspective of the eye is different from that of the whole subject in the video, just to mention a few.

Monday, November 14, 2011

What is the Nyquist Limit and what is its significance to photographers?

Question

The Nyquist Limit is frequently mentioned in the context of lens and sensor resolution.
What is it and what is its significance to photographers?

Here is an example of it being used by DPReview.com in their resolution testing.

Vertical resolution of the Nikon D7000

Answer

Please note that the following is a simplification of how things actually work

Background:

In digital photography, a light pattern is focused by the lens onto the image sensor. The image sensor is made up of millions of tiny light-sensitive sensors whose measurements are combined to form a 2-dimential array of pixels. Each tiny sensor produces a single light intensity measurement. For simplicity, I will look at the 1-dimensional case. (Think of this as a slice that looks at only a single row of pixels).

Sampling:

Our row of tiny sensors, each of which is measuring a single point of light, is performing sampling of a continuous signal (the light coming through the lens) to produce a discrete signal (light intensity values at each evenly spaced pixel).

Sampling Theorem:

The minimum sampling rate (i.e., the number of sensors per inch) that produces a signal that still contains all of the original signal’s information is known as the Nyquist rate, which is twice the maximum frequency in the original signal. The top plot in the figure below shows a 1Hz sine wave sampled at the Nyquist rate, which for this sine wave is 2Hz. The resulting discrete signal, shown in red, contains the same information as the discrete signal plotted beneath it, which was sampled at a frequency of 10Hz. While a slight over simplification, it is essentially true that no information is lost when the original sample rate is known, and the highest frequency in the original signal is less than half the sample rate.

sampling at 2f sampling at 10f

Effects of under sampling:

If the sample frequency were less than 2 times the maximum frequency of the signal, then the signal is said to be under sampled. In that case, it is not possible to reconstruct the original continuous signal from the discrete one. An illustration of why this is the case can be found in the figure below. There, two sine waves of different frequencies sampled at the same rate produce the same set of discrete points. These two sine waves are called aliases of each other.

Aliases

All discrete and digital signals have an infinite number of aliases, which correspond to all the sine waves that could produce the discrete signals. While the existence of these aliases may seem to present a problem when reconstructing the original signal, the solution is to ignore all signal content above the maximum frequency of the original signal. This is equivalent to assuming that the sampled points were taken from the lowest possible frequency sinusoid. Trouble arises when aliases overlap, which can happen when a signal is under sampled.

But Photographs Don't Look Like Sinusoidal Waves. How is all this Relevant?

The reason all of this matters for images is that through application of the Fourier Series, any signal of finite length can be represented as a sum of sinusoids. This means that even if a picture has no discernable wave pattern, it can still be represented as a sequence of sinusoids of different frequencies. The highest frequency that can be represented in the image is half the Nyquist rate (sampling frequency).


Meanings of Similar Terms:

Nyquist rate - The lowest possible sampling frequency that can be used while still guaranteeing the possibility of perfect reconstruction of the original continuous signal.

Nyquist frequency - The highest frequency continuous signal that can be represented by a discreet signal (for a given sampling frequency).

These two terms are two sides of the same coin. The first gives you a bound on sampling rate as a function of max frequency. The second gives you the max possible frequency as a function of sampling rate. See Wikipedia: Nyquist frequency for further reading.

Nyquist Limit is another name for Nyquist frequency. See wolfram.com: Nyquist Frequency

Friday, October 14, 2011

Does shooting at lower RAW resolution using crop sensor camera mimics qualities of full frame cameras?

Question

I'm not talking about changes to the focal length.

I've read many post that say in full frame camera the pixel density is lower compared to crop sensor camera's and so it captures more light and has thus has better ISO performance and greater dynamic range. So if I change by crop sensor camera to shoot at a lower resolution, will that equate to a better pixel density and mimic the performance of a full frame (or medium format) or will it always shoot at maximum resolution and the reduce the size?

--EDIT: 1--
I've a Canon 60D and I've 3 options for RAW image sizes (RAW, M-RAW amd S-RAW). If RAW is just a dump from the Camera sensors, How can their be 3 different sizes? Does the camera also scale down RAW images as well?

Answer

Given that you have a Canon, the lower RAW modes, mRAW and sRAW, DO INDEED UTILIZE ALL of the available sensor pixels to produce a richer result without the need for bayer interpolation. The actual output format, while it is still contained within a .cr2 Canon RAW image file, is encoded in a Y'CbCr format, similar to many video pulldown formats. It stores luminance information for each FULL pixel (2x2 quad of 1 red, 1 blue, and 2 green pixels), and each chrominance channel is derived from half pixel data (1x2 pair of 1 red+1 green or 1 blue+1 green).

I am not exactly certain what the specific low-level hardware read and encoding differences between mRAW and sRAW are, however generally speaking the smaller the output format, the more sensor pixel input information you can use for each output pixel. The small amount of interpolation present in m/sRAW is moot, as both formats interpolate far less than native RAW. It should also be noted that neither mRAW nor sRAW are actual "RAW" formats in the normal sense...sensor data IS processed and converted into something else before it is saved to a .cr2 file.

For more details about YUV derived formats and Canon sRAW, see my answer here: Why isn't the xvYCC color space seeing uptake for still photography?

From "Understanding What is stored in a Canon RAW .CR2 file":

The sRaw format (for "small RAW") was introduced with the 1D Mark III in 2007. It is a smaller version of the RAW picture.

For the 1D Mark III, then the 1Ds Mark III and the 40D (all with the Digic III), the sRaw size is exactly 1/4 (one fourth) of the RAW size. We can thus suppose than each group of 4 "sensor pixels" is summarized into 1 "pixel" for the sRaw.

With the 50D and the 5D Mark II (with the Digic IV chip), the 1/4th size RAW is still there (sRaw2), and a half size RAW is also appearing : sRaw1. With the 7D, the half size raw is called mraw (same encoding as sraw1), 1/4th raw is called sraw (like the sraw2).

the sRaw lossless Jpeg is always encoded with 3 colors component (nb_comp) and 15 bits.

Jpeg code of Dcraw was first modified (8.79) to handle sRaw because of the h=2 value of the first component (grey background in the table). Normal RAW have always h=1. Starting with the 50D, we have v=2 instead of v=1 (orange in the table). Dcraw 8.89 is the first version to handle this and the sraw1 from 50d and 5D Mark II.

"h" is the horizontal sampling factor and "v" the vertical sampling factor. It specifies how many horizontal/vertical data unit are encoded in each MCU (minimum coded unit). See T-81, page 36.

3.2.1 sRaw and sRaw2 format

h=2 means that the decompressed data will contain 2 values for the first component, 1 for column n and 1 for column n+1. With the 2 other components, decompressed sraw and sraw2 (which all have h=2 & v=1), always have 4 elementary values

[ y1 y2 x z ] [ y1 y2 x z ] [ y1 y2 x z ] ...
(y1 and y2 for first component)

Every "pixel" in sRAW and mRAW images contain four components...a split Y' component (y1 and y2), as well as an x (Chrominance Blue) and z (Chrominance Red). All four components (from a 1/2 image perspective, sRAW1/mRAW) have a column height of 2 (h) and a width of 1 (v). This indicates that the Luminance value (Y') is comprised of a FULL 2x2 pixel quad...or two 2x1 pixel columns stored in y1 and y2.

The references below do not seem to specifically state this, so I am speculating a bit here, however with the sRAW2 (1/4 raw) I believe Luminance information would be derived from a 4x4 pixel block where h=4 and v=2. Encoding chrominance would get more complex at a 1/4 size image, as the bayer color filter array on the sensor is not arranged in neat red and blue columns. I am unsure whether alternating 2x1 height columns are processed for each Cr and Cb component, or if some other form of interpolation is performed. One thing is certain...the interpolation of source data is always larger than the output data, and no overlapping (as in normal bayer interpolation) occurs as far as I can tell.

Finally, sRAW1/mRAW and sRAW/sRAW2 are compressed using a lossless compression algorithm. This is a critical distinction between these formats and JPEG, which also uses a ycc type encoding. JPEG performs lossy compression, making it impossible to restore pixels back to their exact original representation. Canon's s/mRAW formats are indeed able to be restored back to original full precision 15-bit image data.

References:

Wednesday, October 5, 2011

Why does viewfinder spec state 3 times more dots than there are pixels?

Question

My DMC-G2 has a viewfinder spec of 1,440,000 dots, but I read a review that says it is really 480,000 pixels:

The electronic viewfinder has an extremely high resolution of 1,440,000 dots (480,000 pixels), offering a 100% field of view and 1.4x magnification. The Panasonic G2's viewfinder has a generous +/-4.0 diopter adjustment range, and a rather tight 17.5mm eye point.

What gives? How am I supposed to compare with other cameras?

Answer

I'm a bit skeptical about what they are stating. It says that the viewfinder is "1,440,000 dots equiv". The "equiv" term is an annoying marketing term used when trying to be competitive without stating the true nature of something, they are simply stating it is "equivalent to" such a thing. The Electronic Viewfinder is "equivalent" to a "1,440,000 dot" resolution. Whatever that means, who knows, but I doubt its actually truly 1.4 million dots.

EDIT: Based on the linked review, the EV has 480,000 "pixels" comprised of 1,440,000 "dots". This is a wacky marketing way of saying that it has 480,000 dots each of red, green, and blue, the triplets of which make up a resolution of 480,000 total pixels in a 4:3 form factor. This boils down to a EV screen size of around 1470x1100 pixes.

Comparing the viewfinder with other DSLR's. This viewfinder is 100% coverage and 1.4x magnification. The magnification is multiplied by the sensor size, which is 17.3x13.0mm. Thats a viewfinder size of 24.22x18.2mm, which is basically APS-C size. In contrast, a Canon or Nikon APS-C DSLR will usually have 95-97% coverage and anywhere between 0.70x to 1.0x magnification, depending on the model. Most of the entry-level DSLR's are around 0.85-0.95x, while the Canon 7D is a 100% 1.0x APS-C viewfinder. A Canon 5D Mark II is a 98% 0.71x viewfinder, which is again about the size of an APS-C sensor.

The LCD screen on the back has "460K dots" in it, which these days is pretty low. Most of the more recent Canon and Nikon LCD screens have 920k or 1040k dots.

Thursday, September 29, 2011

Is it worth investing in a used 35 mm Film camera?

Question

I've a Canon 60D and I'm mainly interested in shooting landscapes. I feel very interested in buying a used canon EOS film camera (since my EF lenses are compatible).
I would like to take pictures from my DSLR and then use the same meter reading on the SLR to take a picture. I'm planning on scanning the negatives myself to the maximum resolution and the assumption is that the picture from the film camera would be lot more colorful and sharper.

Would their be a noticeable difference by using a film camera? considering that my 60D comes with 18 Mega Pixels.

Sharpness and resolution matter to me only because I usually end up cropping my pictures.

Also I'm planning on using using films with ISO of 50 or 100.
The used camera I'm interested in cost around $200.

Answer

It certainly is not worth investing in a 35mm film camera for the perceived higher resolution, additional color, or sharpness.

To get results you will likely have to either invest in, or at least have access to a drum scanner that gives you the highest resolution possible right now. Otherwise you will likely be scanning on a flatbed that almost certainly does not produce resolution even near the Canon 60D.

Are you trying to print 24x30inch prints at 360dpi? Sure, grab a 35mm camera, a $20,000 drum scanner, and you may be able to achieve high resolution that would benefit images of this size. You also might not achieve that.

It sounds like the main issue is that you usually end up cropping your images. If this is the case, it sounds like you either need to frame up the subject better before you take the image, or invest in further reaching lenses.

Tuesday, September 27, 2011

Does shooting at lower RAW resolution using crop sensor camera mimics qualities of full frame cameras?

Question

I'm not talking about changes to the focal length.

I've read many post that say in full frame camera the pixel density is lower compared to crop sensor camera's and so it captures more light and has thus has better ISO performance and greater dynamic range. So if I change by crop sensor camera to shoot at a lower resolution, will that equate to a better pixel density and mimic the performance of a full frame (or medium format) or will it always shoot at maximum resolution and the reduce the size?

--EDIT: 1--
I've a Canon 60D and I've 3 options for RAW image sizes (RAW, M-RAW amd S-RAW). If RAW is just a dump from the Camera sensors, How can their be 3 different sizes? Does the camera also scale down RAW images as well?

Answer

Given that you have a Canon, the lower RAW modes, mRAW and sRAW, DO INDEED UTILIZE ALL of the available sensor pixels to produce a richer result without the need for bayer interpolation. The actual output format, while it is still contained within a .cr2 Canon RAW image file, is encoded in a Y'CbCr format, similar to many video pulldown formats. It stores luminance information for each FULL pixel (2x2 quad of 1 red, 1 blue, and 2 green pixels), and each chrominance channel is derived from half pixel data (1x2 pair of 1 red+1 green or 1 blue+1 green).

I am not exactly certain what the specific low-level hardware read and encoding differences between mRAW and sRAW are, however generally speaking the smaller the output format, the more sensor pixel input information you can use for each output pixel. The small amount of interpolation present in m/sRAW is moot, as both formats interpolate far less than native RAW. It should also be noted that neither mRAW nor sRAW are actual "RAW" formats in the normal sense...sensor data IS processed and converted into something else before it is saved to a .cr2 file.

For more details about YUV derived formats and Canon sRAW, see my answer here: Why isn't the xvYCC color space seeing uptake for still photography?

From "Understanding What is stored in a Canon RAW .CR2 file":

The sRaw format (for "small RAW") was introduced with the 1D Mark III in 2007. It is a smaller version of the RAW picture.

For the 1D Mark III, then the 1Ds Mark III and the 40D (all with the Digic III), the sRaw size is exactly 1/4 (one fourth) of the RAW size. We can thus suppose than each group of 4 "sensor pixels" is summarized into 1 "pixel" for the sRaw.

With the 50D and the 5D Mark II (with the Digic IV chip), the 1/4th size RAW is still there (sRaw2), and a half size RAW is also appearing : sRaw1. With the 7D, the half size raw is called mraw (same encoding as sraw1), 1/4th raw is called sraw (like the sraw2).

the sRaw lossless Jpeg is always encoded with 3 colors component (nb_comp) and 15 bits.

Jpeg code of Dcraw was first modified (8.79) to handle sRaw because of the h=2 value of the first component (grey background in the table). Normal RAW have always h=1. Starting with the 50D, we have v=2 instead of v=1 (orange in the table). Dcraw 8.89 is the first version to handle this and the sraw1 from 50d and 5D Mark II.

"h" is the horizontal sampling factor and "v" the vertical sampling factor. It specifies how many horizontal/vertical data unit are encoded in each MCU (minimum coded unit). See T-81, page 36.

3.2.1 sRaw and sRaw2 format

h=2 means that the decompressed data will contain 2 values for the first component, 1 for column n and 1 for column n+1. With the 2 other components, decompressed sraw and sraw2 (which all have h=2 & v=1), always have 4 elementary values

[ y1 y2 x z ] [ y1 y2 x z ] [ y1 y2 x z ] ...
(y1 and y2 for first component)

Every "pixel" in sRAW and mRAW images contain four components...a split Y' component (y1 and y2), as well as an x (Chrominance Blue) and z (Chrominance Red). All four components (from a 1/2 image perspective, sRAW1/mRAW) have a column height of 2 (h) and a width of 1 (v). This indicates that the Luminance value (Y') is comprised of a FULL 2x2 pixel quad...or two 2x1 pixel columns stored in y1 and y2.

The references below do not seem to specifically state this, so I am speculating a bit here, however with the sRAW2 (1/4 raw) I believe Luminance information would be derived from a 4x4 pixel block where h=4 and v=2. Encoding chrominance would get more complex at a 1/4 size image, as the bayer color filter array on the sensor is not arranged in neat red and blue columns. I am unsure whether alternating 2x1 height columns are processed for each Cr and Cb component, or if some other form of interpolation is performed. One thing is certain...the interpolation of source data is always larger than the output data, and no overlapping (as in normal bayer interpolation) occurs as far as I can tell.

Finally, sRAW1/mRAW and sRAW/sRAW2 are compressed using a lossless compression algorithm. This is a critical distinction between these formats and JPEG, which also uses a ycc type encoding. JPEG performs lossy compression, making it impossible to restore pixels back to their exact original representation. Canon's s/mRAW formats are indeed able to be restored back to original full precision 15-bit image data.

References:

Monday, September 19, 2011

Why are low-resolution versions of my images shown in Adobe Bridge?

Question

When I browse photos in Adobe Bridge, they are often not as sharp as they really are, as if Bridge loads a low-res version of the photo for speed. This makes it hard to pick photos that are good, as I need to open them in Camera Raw to see how sharp they are first. The same low-res image is shown in Camera Raw the first seconds, until the image is "loaded fully" (I suppose).

Can I make Bridge show the high-res image?

Answer

eek this is annoying - I have the same problem - have you checked this post out forums.adobe.com/thread/561800?tstart=0

Hope this works!

Rob

Thursday, August 4, 2011

What is the difference between image size and image quality?

Question

I have a Casio EX-S12. It has a setting for image size, but also a separate setting for what it calls "image quality". There are three image quality values: "Fine", "Normal", and "Economy".

The Casio manual is not clear on what image "quality" actually means -- specifically how it's different from image size. All they say is that the "Fine" setting "helps to bring out details when shooting a finely detailed image of nature that includes dense tree branches or leaves, or an image of a complex pattern." I'm confused because isn't this what image size is all about (more pixels = more detail)?

In terms of memory usage, the manual also says that for a 5 megapixel picture, a "Fine" image takes up 2.99 MB, a "Normal" image takes up 1.62 MB, and an "Economy" image takes up 1.12 MB, so this "image quality" setting of theirs is certainly having a significant impact on memory usage.

My question is, what exactly is "image quality", if it's not image size? What is the "thing" that is taking up additional memory?

Thank you.

Answer

Image size is what if often called resolution, basically the number of pixels stored in the image file. So on a 12 megapixel camera, you can usually choose between 12 MP, 6 MP and 3 MP or similar values.

Image quality is independent of size and is usually called compression. This controls how much information is discarded from images while they are saved.

You can read this article which I wrote several years ago for a comparison between the two.

Sunday, July 17, 2011

how do you determine the size of an image based on resolution , ppi, and type?

Question

I'd like to be able to determine the size of a an image with a particular resolution/ppi for JPEG & PNG formats.

Are there any online tools to do this?

Answer

If I get you right, you want to predict an images (JPEG and PNG) file size before your take the picture.

In short: I do not think that this is doable, without actually taking the picture. Here's why:

PPI: First DPI / PPI does not apply to a digitally stored image. Take an arbitrary image change the dpi without recalculation of the image so the pixels in length and width are equal and produce a 7, 72, 96, 960 dpi jpeg version. All will have the same file size (and also be displayed the same size at 100%). PPI information is only used when printed, for example.

Resolution: Yes, the resolution (y-pixel - x-pixel) of the sensor can be taken into calculation precisely.

JPEG / PNG - Type: Both of these formats (types) will compress the data the sensor provides by using compression algorithms. Hence the compression rate, that finally will define the file size, depends on the data which you only know if you take the picture.

If you would take the color depth (bits per pixel) into account and shoot in uncompressed RAW, a forecast of the files size could be calculated I guess. However, since the RAW file will contain all meta data (camera settings and so on) too, you'll end up with an estimation again.

Monday, July 11, 2011

Is it possible to increase the pixel density of an image ?

Question

I have taken a picture whose resolution is less. I can resize the image easily (i.e I can scale to higher resolution) but the image quality goes for a toss, which is true because the image might not have enough pixels to scale properly.

  1. Is resizing a means to increasing the resolution of the image ?

  2. Is it possible to increase the pixel density of the image and then resize, so that
    quality of the image is not affected much?

I mainly use GIMP and Picasa.

Answer

In general it is not possible to increase the size/resolution/pixel density of an image after it has been captured. If the detail was never present it can't be replaced.

There are ways to increase the number of pixels whilst minimizing artifacts (an example being fractal based image resizing). These methods are useful when you need to print large without seeing pixel artifacts. But the results are nothing like what you'd get with an image that was higher resolution to start with.