Repository navigation
iOS: upload the unedited original (e.g. ProRAW DNG) next to the edited render, stacked #32367
Closed
pietervanstee
started this conversation in
Feature Request
Replies: 1 comment
|
This discussion has automatically been closed as it is likely a duplicate. We get a lot of duplicate threads each day, which is why we ask you in the template to confirm that you searched for duplicates before opening one. If you're sure this is not a duplicate, please leave a comment and we will reopen the thread if necessary. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem
On iOS, the app uploads the current version of a photo. When a ProRAW shot was edited in
the Photos app before the first backup (colour, light, crop, or a 16:9 / 1:1 capture, which
iOS stores as a 4:3 DNG plus a crop edit), the server only ever receives the rendered JPEG.
The DNG never leaves the phone. PR #31082 (3.3.0) stacks a later edit over an
already-backed-up original, but it cannot recover an original that was edited before the
upload. Issue #5818 covers the same resource question for Portrait/Cinematic data.
On our server (3.3.1, 3 iPhones) all 70 lowercase
.jpeguploads from the Pro Max phonessince 2026-08 are such cases; 270 real DNGs are all unedited 4:3 shots.
Why it is technically possible
PhotoKit keeps the original capture of an edited asset:
PHAssetResource.assetResources(for:)returns.photo(original capture),.fullSizePhoto(edited render) and.adjustmentData(the edit recipe) for an editedasset (Apple docs: PHAssetResource, PHAssetResourceType).
StorageRepository.getFileForAssetcallsentity.originFile. Inphoto_manager3.9.0 (the pin inmobile/pubspec.yamlatv3.3.1) that reaches
PMManager.mfetchOriginImageFile→getCurrentResource.The native hash path
mobile/ios/Runner/Sync/PHAssetExtensions.swiftgetResource()(lines 54-76) uses the same order: the resource with
isCurrent, else the full-size one.Checked at tag
v3.3.1.photo_manager3.10.0 addsasset.darwin.hasAdjustments,asset.darwin.getBaseFile()(
isOrigindefaults to true) andasset.darwin.getAdjustmentData(), which expose theoriginal and the recipe (3.10.0 changelog,
lib/src/types/darwin.dart).Proposed behaviour
hasAdjustmentsis true, upload the edited render as today, then upload the basefile (
asset.darwin.getBaseFile()) as a second asset with the original file name(
IMG_xxxx.DNG), deduplicated by its own checksum.stacks a later edit.
.aaeadjustment data as a sidecar (links to [BUG] In the iOS app, the metadata of the backed up file is different. #5818).bandwidth under control.
Caveats to handle
.photomay need a network fetch (the app already handles thisfor the current resource).
.alternatePhoto; pick the DNG by UTI..video/.fullSizeVideohandling, out of scope here.Workaround today
Let the app back up the DNG first, then edit. For an already-edited photo: Photos → Edit →
Revert (loses the edit) or Mac Photos → File → Export → Export Unmodified Original, then
upload with the web or CLI.
I am happy to test a build on 3 iPhones (16 Pro Max, iOS 26) with ProRAW.
All reactions