The only available tool able to create a RAW file is, as far as I know, a camera, and there are no standard tools to manipulate it. I've heard that's why RAW files are used in different photography competitions to prove a photographer has not manipulated a submitted photograph.

However, RAW files are just data files and any bits can be manipulated.

What makes RAW files difficult to be an object of manipulation?


6 Answers 6


Nothing makes raw files difficult to manipulate for someone with the right expertise and tools. It's just that there aren't many folks around who have those tools and expertise.

The tools needed to manipulate a raw file into a jpeg are much more widespread and well known than those needed to manipulate a raw file into a different raw file. That is probably where the perception that raw files are more difficult to manipulate comes from: most organizers of such contests are more familiar themselves with how to produce heavily manipulated jpegs from raw files. Most of them are probably not aware that raw data can be manipulated at all, much less how one would go about doing it. I mean, they don't even understand what 300 dpi (doesn't) mean in a display-size agnostic digital environment.

Ironically, the news organization Reuters has it the other way around: They will only accept images that (appear to) have been generated as jpegs in camera at the time the images were shot.

  • 2
    Interesting. JPEGs can be manipulated so much more easily. So why Reuters does it?
    – dzieciou
    Dec 1, 2016 at 22:09
  • 3
    @dzieciou If memory serves, I remember something about a news agency (possibly Reuters) only accepting JPEGs generated by the camera at the time of the shooting to help identify photos that have been doctored. It's very hard to doctor a JPEG without leaving artifacts, so if the camera made the JPEG, they can reasonably assume it is not altered.
    – Cort Ammon
    Dec 2, 2016 at 1:03
  • 12
    @CortAmmon But it is fairly easy to create a jpeg from raw data after the fact and then alter the metadata to make it appear to have been generated in camera.
    – Michael C
    Dec 2, 2016 at 1:25
  • 8
    @MichaelClark If I were to take a guess at the delicate world of image forensics, it may be harder to make a JPEG that looks like it was generated by the camera's particular JPEG compression algorithm than meets the eye. I don't think it'd stop a determined forger (that'd call for cryptographic signing of images), but it'd cut down on a lot of it.
    – Cort Ammon
    Dec 2, 2016 at 3:04
  • 4
    I think the Reuters rule was about forbidding photographers from going crazy with post processing that might change the impression of the image and less about outright manipulation. Limiting the photographer to the settings of a camera is a relatively simple rule compared to legislating which photoshop filters are acceptable. Dec 2, 2016 at 17:07

A RAW file is little more than a container for the output of a camera sensor. It has to be processed into an image which gives it full color information at each pixel. As such there are no programs intended to manipulate a RAW file since it is meant as input to RAW conversion software.

Since it is just made of bits like any other digital file one can of course change any portion with a binary editor for example. What is harder would be to make coherent changes to the RAW file which that the changes would appear natural. You cannot crop a RAW file because the image size would no longer produce what the camera does. Adding or removing objects from the scene would require one to do the inverse transformation of a RAW conversion specific to a particular camera.

  • There are a few tools that transform raw data and then output that data still in raw form (i.e. non-debayered/non-demosaiced). The camera firmware that creates M-RAW and S-RAW files in some Canon EOS cameras, for instance. The Digital Lens Optimizer tool in Canon's Digital Photo Professional, for another. For more about DLO, please see: photo.stackexchange.com/questions/35324/…
    – Michael C
    Dec 2, 2016 at 16:16

There are better formats for lossless, high bit-depth image storage and exchange. The main benefit of raw files is that they contain minimally-processed sensor data. So there's no compelling reason for anyone to put the (fairly significant) effort in to writing the code to write raw files. This means that submitting the raw files is a practical way to demonstrate (i) possession of the original shot and (ii) what the original shot looked like. It's poor evidence of legal ownership of the original.

  • Given how much a RAW image can be changed in post-processing, I'm not sure it is necessarily a good way of demonstrating what the original shot looked like. It's an okay way of demonstrating the original shot crop and content, though.
    – user
    Dec 3, 2016 at 17:33
  • @MichaelKjörling, that's fair. In things like wildlife photography, editing out bait (for example) may be contrary to the intent of the competition. In an extreme case it would be possible to remove evidence of captivity in post. The raw would show this up.
    – Chris H
    Dec 3, 2016 at 18:40

RAW files are hard to manipulate because there are no tools for this.

There are no tools because manipulating them is pointless.

RAW files don't hold standard images. They hold the data read directly from the sensor of one specific camera model. They need to be processed in a way specific to each camera model to get a standard image.

In order to "display" a raw file, you must have specific details of the camera model it came from—this is why RAW converters like Lightroom need to get an update for each new released camera. In contrast, JPEGs or PNGs are designed to be displayable on any device without needing to know where they came from. They are meant to be able to hold any image.

I hope this makes it clear that there is absolutely no point in producing RAW files in any other way than directly in the camera. (Unless you want to commit fraud, or unless you want to reverse engineer a specific RAW format to understand a camera better, or to produce your own RAW converter for it.)

  • So there's no point to the image improvements one can gain using the Digital Lens Optimizer tool of Canon's Digital Photo Professional that applies very detailed lens correction to the raw file and appends it with a second file of equal size containing the "corrected" raw file? martinbaileyphotography.com/2012/07/14/…
    – Michael C
    Dec 2, 2016 at 16:26
  • 1
    @MichaelClark, judging by your own comment in the question you linked, there is no point to the DLO saving as RAW rather than as TIFF. Dec 2, 2016 at 20:57
  • TIFF "bakes in" black point, white point, color balance, etc. Raw does not.
    – Michael C
    Dec 3, 2016 at 12:07
  • @PeterTaylor There is if you then do raw conversion and global editing using DPP rather than Lr!
    – Michael C
    Dec 3, 2016 at 12:09
  • Once you leave the ACR module from within Lr or PS you're no longer working on the raw data anyway, you're working on an internal equivalent of a 16-bit TIFF.
    – Michael C
    Dec 3, 2016 at 12:13

A typical camera sensor does not capture RGB pixels, but instead captures input distinct red-sensing pixels, green-sensing pixels, and blue-sensing pixels at slightly different locations; a raw file will report the values of the individual pixels as captured.

When a raw file is converted to an RGB pixel format, each pixel in the output file will typically be a weighted and filtered average of a number of pixels on the original sensor. Once the data is converted, each pixel in the resulting file will be capable of independently representing any color. If one wants to e.g. adjust the saturation in a file of RGB pixels, each individual pixel's red value can be based upon its blue and green values, and likewise adjust each pixel's blue based upon its red and green, and adjust its green based upon its red and blue.

If one wanted to apply a white-balance adjustment to a raw file, however, one wouldn't be able to adjust the color of individual pixels, since each individual pixel is only capable of sensing a single lightness value. If one wants to reduce the saturation of a raw image of a red object, it wouldn't be possible to increase the blue and green values of all the red-sensing pixels; instead, one would have to increase the reported values for blue-sensing and green-sensing pixels that were near brightly-lit red-sensing pixels. Such operations are not difficult, but each time they are applied will degrade the image a little more. By contrast, the act of converting sensor data to an RGB picture is generally lossy, but such loss need only be incurred once.

  • 1
    That's a very naive view of the information contained by the data from each pixel in a raw file. There are no red, green, or blue pixels in a raw file. There are only monochromatic luminance values for each pixel. Yes, the pixels have been filtered by the Bayer mask that has three different filters centered on R, G, & B. But light from a much wider spectrum than the single wavelength on which each filter is centered is allowed to pass through the mask. It is much like using a R, G, or B filter in front of B&W film. You still have a B&W negative with tonal values shifted for certain colors.
    – Michael C
    Dec 1, 2016 at 23:35
  • 2
    @MichaelClark: I clarified the pixels as red-sensing, green-sensing, and blue-sensing, to clarify that the color name describes what the pixel senses. I didn't want to get too deep into the details of how things work beyond noting that the pixels which are used for capturing the red, green, and blue parts of an image are in slightly different places, which means that anything which shifts information between colors will slightly distort its position.
    – supercat
    Dec 1, 2016 at 23:46
  • 2
    @MichaelClark: While it's true that the pixels that are intended to sense red will also sense a certain amount of blue and green, and likewise for other colors, that doesn't affect the fact that adjusting things like saturation will distort the apparent position of light hitting the sensor, and that repeated adjustments would progressively degrade the image.
    – supercat
    Dec 2, 2016 at 0:12
  • 2
    @MichaelClark This continues to seem like a semi-mystical view of how RAW files work. While it is true that the RAW filters aren't perfect primaries, RAW conversion treats them exactly as if they are (for the sensors' native color space). The same debayering / demosaicing algorithms would work with idealized perfect filters.
    – mattdm
    Dec 2, 2016 at 8:40
  • 1
    It only seems mystical to those who don't understand what information a raw file contains and, more importantly, what it does not. freefall.purrsia.com/ff300/fv00255.htm
    – Michael C
    Dec 2, 2016 at 13:11

Because there is no need to do it.

Advanced manipulation programs usually are non destructive, so programs usually use original image, but save manipulation in an additional file (or database). For simple editing, the sidecar .xmp is used.

There is huge advantage to have non destructive workflow. One for all: easier to backup, but you can always have the original information to do further manipulations, without losing anything.

I think UFRaw can also save raw.

Technically it is not difficult to create them: common raw files are just compressed TIFF files, with some well know interpretation of color and geometry of pixels (because it is used by the readers), and with some additional EXIF information.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.