Photogrammetry: RAW and JPG compared
The same 13 drone photos processed three ways: RAW files, in-camera JPGs and JPGs developed from RAW. Tie points, dense cloud, mesh, DEM, orthophoto and processing times.

In this article I’ll show you the differences between running photogrammetric processing on RAW images, on JPG files recorded straight to the memory card in the field without any processing, and on JPG photos developed from the same RAW files.
There are differences.
They don’t overturn the result of a photogrammetric survey or compromise its data, but they’re there.
I’ll leave it to you to decide which is the best choice, but I’ll share a field test and the operational choices I make in a survey.
I hope it’s useful!
(Let me know if it was…)
I shoot RAW
I’m a die-hard fan of the RAW file.
I’ll tell you straight away, to avoid any misunderstanding.
I always have been, ever since I started shooting digital.
I used them right away, with the first digital SLRs (Nikon D70, D100, …), and appreciated their advantages.
You recover shadows, lower highlights, improve contrast, adjust tones…
And you do it all without losing information or “ruining” the file.
Even though a RAW file takes up a lot of space on the camera’s memory card and on the hard disk where you archive it, I stay loyal to it.
Miracles don’t happen.
A “blown-out” photo stays that way.
The same goes for motion blur or out-of-focus shots.
But I’m always on the side of RAW.
There, I’ve said it…
But I’ll also tell you that I don’t use RAW files directly in the photogrammetric process.
I start from them and create JPGs optimised for software processing.
RAW in photogrammetry
My passion for RAW carries over into photogrammetry and aerial photogrammetry.
In a photogrammetric survey I always shoot RAW images.
The instruments I use allow it: Nikon D800, DJI Phantom 4 Pro.
The only case I don’t is when I use the DJI Spark, which only shoots JPG.
A pity!
Here the Parrot Anafi wins…
Oh, and I shoot RAW whether it’s a project of 50 photos or 5,000.
That’s no joke, it really happened!
🙂
OK, I think I got a bit carried away with this RAW business.
But there are reasons to shoot RAW rather than JPG.
And they make sense.
Some time ago I published an article on retouching RAW files and optimising them for photogrammetric processing; you’ll find it here. If you’d like to read it, you’ll find some information there.
It talks about RAW, the differences with JPG, the advantages for photogrammetry, and photo editing with all the concrete steps I take in the “digital darkroom”.
There’s a lot of information there, so I won’t repeat it here.
I’d rather go straight to the subject of this post.
A practical case: multiple photogrammetric processing runs
If you’ve read other articles on this blog you’ll know I like doing tests.
They help you get better at your work by becoming aware of the tools you use.
I couldn’t not do one for this topic too.
And here I’m happy to share the steps and results with you.
Nadir photos in an aerial photogrammetric survey
I took some photos from an aerial photogrammetric flight over a landfill. I have quite a bit of data on hand because it’s an area I survey periodically, for the progress of the ongoing works and volume calculations of cut and fill.

I took 13 photos shot by the DJI Phantom 4 Pro drone during one of the automatic flight missions.
They’re nadir photos from a small piece of one of the many strips flown to cover the whole area.
I chose very few photos so I could run all the photogrammetric processing quickly.
More photos means more time.
And the progression isn’t linear!
Below are two screenshots of the camera positions relative to the tie points of the sparse cloud (first image) and the dense cloud (second image).


They were taken during an automatic flight mission with the drone’s height varying with the terrain elevation (to keep the GSD constant).
The Phantom 4 Pro lets you record image files on the memory card in three ways:
- RAW files only (actually in DNG format);
- JPG files only;
- for each photo, one RAW file and one JPG file.
I chose the last option.
Back in the office I therefore had a set of raw images, the RAW/DNG files, and a set of as many JPG images.
These JPGs had been adjusted (fairly mildly, but it could be stronger) by the drone’s brain, immediately after the shot and before being written to the memory card.
3 processing runs compared
To see the differences between using one type of file and the others, I ran 3 different but identical processing runs:
- the first (1) used the raw RAW/DNG files;
- the second (2) took the JPG images as recorded at the time of the shot;
- the third (3) used JPG images derived by editing and processing the RAW files (with Adobe Lightroom, following the steps of the article linked above).
I processed the photos with Agisoft Metashape Pro.
Among the programs I use, it’s the one that lets me load RAW files directly into the photogrammetric project.
The other photogrammetry software I often rely on, LiMapper, doesn’t (for now…).
The processing steps were:
- Image alignment;
- Dense cloud generation;
- Triangle mesh creation;
- DEM processing;
- Orthophoto production.
I used the same settings for each run with different photos.
I didn’t use GCPs or check points.
I hope you’ll turn a blind eye to this formal omission.
I feel justified, though, because I’m not doing a survey, only comparing the results produced.
The number of points and mesh faces, as well as the quality of the DEM and orthophoto, are independent of the model’s orientation.
So no ground control (in the general survey of the landfill there was plenty!).
Now let’s look at the results.
Pay attention to the outputs but also to the processing time.
It isn’t negligible for big projects.
First, comparing images
First, though, I think it’s worth showing you one photo from the dataset in the three different formats.
The images below are low-resolution, made to load on the blog pages (without making you wait too long).
They should really be judged on the original files.
But you can get a preliminary idea.

This is the RAW file.
Actually it’s the preview of the raw file.
To see it “for real” you’d need editing software.
It weighs 38 MB. All 13 photos together come to 498 MB.

This is the JPG recorded in flight when the photo was taken.
The file is 8 MB, and all the photos come to 107 MB.

And this is the JPG developed from the RAW file.
It weighs 18 MB; all the images total 234 MB.
I don’t think the differences show much.
They’re there.
I’ll describe them briefly.
The raw RAW file is “untreated”.
Nobody has applied any adjustment to it.
That’s why it looks “washed out”, not very sharp or contrasty, with dark highlights and light shadows, and fairly low saturation too.
The in-flight JPG has more contrast, saturation and sharpness.
The JPG developed in post-production takes the contrast and detail of the in-camera JPG but recovers information in the shadows and highlights.
Below is a comparison of two 100% crops of the same area from the two JPG files.
First the image recorded at the time of the shot, then the developed one.


Notice how, in the developed file, the shadows are lighter (photographers say more “open”) and the highlights lower.
The detail is the same; in fact the developed image has a bit more.
Tie points and sparse cloud
Now for the numbers and times.
First the sparse cloud made of tie points, the matching points.

- The sparse cloud made directly from the RAW files has 11,376 points and was processed in 38 seconds.
- The tie points from the in-camera JPGs are 12,809 and “came out” in 28 seconds.
- The developed JPGs gave 12,574 matching points in 28 seconds.
The RAW images found fewer tie points, while the in-flight JPGs won the challenge.
They beat the other JPGs by 235 points (2%) and the RAWs by 1,433 (about 12%).
This isn’t surprising if you consider that tie points are searched for based, among other things, on contrast.
With darker shadows and lighter highlights, the in-camera JPGs give more chances of finding contrasting areas to “hook” onto.
The developed JPGs benefit from more detail and, all in all, keep pace.
The RAW files, instead, have little detail and contrast, so they struggle.
And the software took 10 seconds longer than in the other runs.
10 seconds out of about 30 is over 30%.
Not a little…
Dense cloud
In the dense cloud the RAW files get their revenge.

The figures for the clouds are:
- Dense cloud from RAW files: 15,582,178 points in 6’16”;
- Dense cloud from in-camera JPGs: 14,238,239 points in 3’39”;
- Dense cloud from JPGs developed from the RAW files: 14,429,184 in 3’54”;
They look like the results of a decathlon!
All three clouds work.
They’re representative and have no holes or uncertainties.
And that’s good!
The photogrammetry software can really explore all the detail of the raw files to reconstruct a richer cloud.
The first cloud has more than a million points more than the others.
This area is a tenth of the whole area I surveyed, and over the whole survey the gap in points becomes much larger.
But the processing time is higher than in the other two runs.
Almost 50% more.
If you consider that waiting tens of hours for a dense cloud when processing hundreds of images can be normal, you can see what using RAW files could mean for processing time.
The dense cloud from the developed JPGs is a bit larger than the other.
There’s more information in the shadows and highlights, and the imaging and machine learning algorithms use it to create more 3D points.
3D triangle mesh
Now it’s the triangle mesh’s turn.

- The RAW images built a mesh of 3,116,427 faces in 13’29”;
- The undeveloped in-camera JPGs gave a mesh of 2,847,625 faces in 12’11”;
- And the developed JPGs a mesh of 2,885,818 faces in 13’19”.
Well, not much to say here.
Since the mesh is created by turning the dense cloud points into the vertices of lots of triangles, it’s clear that the bigger the dense cloud, the more triangles and so the more mesh faces.
What’s more interesting is that there’s no longer a big difference in processing time, even for generating the data from the RAW files.
This shouldn’t be surprising either.
At this stage the images no longer play a heavy part in the processing.
I chose not to colour the mesh vertices, so the software no longer draws information from the photos, only from the dense cloud.
The times to compute the mesh, in the three cases, aren’t very different.
Digital elevation model (DEM)
I used the dense cloud to generate the DEM, the Digital Elevation Model.
Here it’s a DSM (Digital Surface Model) rather than a DTM (Digital Terrain Model).
I wrote an article on the differences between these models, which you can read here.

For the DEM there really are no differences.
- DEM from RAW photos – Resolution 4.7 cm/pixel – Point density: 452 points/m² – 23 seconds;
- DEM from undeveloped in-camera JPGs – Resolution 4.69 cm/pixel – Point density: 454 points/m² – 25 seconds;
- DEM from JPGs developed from the RAW files – Resolution 4.7 cm/pixel – Point density: 452 points/m² – 23 seconds.
It’s really the same data.
Orthophoto
And finally there’s the (nadir) orthophoto.
With the same ground resolution, GSD, of 2.35 cm/pixel for all, the objective difference between the orthophotos is the size of the images, width by height in pixels.
But there are also some qualitative differences, which you can see below.

The orthophoto generated from the RAW files measures 11,379×12,569 pixels and was built in 4’24”.
Like the native images, its overall look has little body (saturation and contrast).

The orthophoto from the undeveloped in-camera JPGs measures 9,573 x 10,801 pixels and took 2’02”.
It has plenty of contrast and is a bit more pleasing to the eye.

And then there’s the last orthophoto, the one made with the JPGs developed from the RAW files.
It measures 9,643 x 10,827 pixels and took 2’10”.
It has less saturation than the other JPG orthophoto, but it’s very detailed and crisp.
So what?
Now that you’ve read all this, what happens?
Well, perhaps you can get an idea of what you think is best for you and your work.
I’ve already told you what I do: I shoot RAW, develop the photos into optimised JPGs and use those in the photogrammetry software (and I get rid of the RAW files after archiving them; I’ll never use them again, but “never say never”).
Now I’ll also tell you what I think, briefly and point by point.
- Even though I’m a champion of shooting RAW, I really don’t feel I can recommend using them directly in SfM software for processing.
Although they produce the largest (dense) point clouds, they’re heavy files that need more storage and longer processing times.
Is it worth it?
I don’t think so.
But I’m ready to be proved wrong! - Leaving out the comparison with RAW processing, the comparison of the two models made with JPGs tips the balance a bit towards the ones developed from the raw data.
To be honest and very frank, though, the differences aren’t that marked or obvious.
They certainly don’t penalise the modelling.
In that sense you could go straight to the drone’s JPGs without worrying about processing hundreds of photos (even if you do it with software that automates the process).
You save time and space.
And the resulting model works well. - This particular case isn’t very complicated in terms of light.
The surveyed area has little tall vegetation casting shadows, and the light during the flight was partly veiled and therefore diffuse.
In higher-contrast situations, where the difference between light and shadow is extreme with the sun blazing, developing the RAW files really lets you recover a lot more information.
And it improves the photogrammetric process, starting from the tie points of the sparse cloud.
Keep it in mind and don’t rule this option out.
For me it’s the default on every job! - If the area is large, you know you’ll take lots of photos (500-600) and you only have one memory card, shoot JPG straight away.
You can’t do otherwise without risking running out of space.
You still need to get the job done. - If it’s a cloudy day with flat, very diffuse light, in a simple area with few vertical features, feel free to shoot JPG directly.
There shouldn’t be big differences in the final result. - You can try changing the camera’s automatic JPG processing settings to find a solution with a bit less contrast than the default.
I use a fairly “flat” profile.
It can help.
But be aware that a JPG has small processing margins, much smaller than a RAW file.
And editing a JPG degrades the file a bit.
If the sensor that recorded it is small (1″), it degrades even more easily than a file from a large sensor (FX 35mm). - JPG doesn’t forgive exposure errors at the time of shooting.
If for some reason you forget a camera setting that shifts the exposure of all the images in the dataset by “one stop”, RAW files let you recover the information; JPGs don’t.
And the photogrammetric processing suffers.
All that said, I’ll keep shooting RAW!
🙂
What do you do?
I’d love to know how you approach a photogrammetric job.
And if you have doubts, questions or comments, you can send me a message or a voice note on Telegram: I’m @paolocorradeghini.
Thanks for your time and attention!
See you soon!
Paolo Corradeghini