Skip to content

[ios/ipad OS]Multi-file ZIP archiving converts HEIF to JPEG and HEVC to H.264 despite "Current" export setting⁠ #202

Description

@7chirrupy1emblazing

When selecting multiple photo and video assets from the iOS/iPadOS system image picker to send as a batch payload, the app automatically compresses the assets into a ZIP archive before initiating the transfer.
During this batch archiving step, iOS automatically transcodes master 10-bit HEIF (⁠.heic⁠) images into JPEGs and re-wraps 10-bit Dolby Vision HEVC (⁠.mov⁠) video streams into standard H.264 containers. This occurs even when the user's system-level export setting on the Share Sheet / Photos settings is explicitly set to "Current" / "Keep Originals".
Steps to Reproduce

  1. Ensure the iOS system photo transfer/export setting is configured to "Current" (or "Keep Originals").
  2. Open Wormhole File Transfer on iOS/iPadOS.
  3. Select 2 or more HEIF (⁠.heic⁠) images and/or 10-bit Dolby Vision HEVC (⁠.mov⁠) videos via the Photo Library picker to trigger a batch upload (ZIP archive creation).
  4. Complete the transfer and inspect the received ZIP archive payload on the receiving device.
    Expected Behavior
    The assets inside the generated ⁠.zip⁠ archive should remain in their raw bitstream formats—preserving ⁠.heic⁠ file extensions, original file sizes, and 10-bit HEVC / Dolby Vision metadata untouched.
    Actual Behavior
    All HEIF images inside the ⁠.zip⁠ archive are converted to ⁠.jpg⁠ format, and HEVC ⁠.mov⁠ videos undergo generation loss / container transcoding to standard H.264, stripping master HDR metadata and reducing file fidelity.
    Root Cause & Suggested Fix
    When requesting asset URLs or reading bitstream data from ⁠PHPickerViewController⁠ or ⁠PHImageManager⁠ for archiving, the iOS pickerdefaults to returning "compatible" media representations unless explicitly instructed otherwise.
    Suggested Remediation:

Configure the underlying ⁠PHPickerConfiguration⁠ asset representation mode to ⁠.current⁠:

// Swift / Native iOS Picker configuration
configuration.preferredAssetRepresentationMode = .current

Ensure the Flutter image/file picker plugin or native iOS bridge requests raw file paths (⁠PHAssetResource⁠) or standard bitstream URLs rather than requesting generic ⁠UIImage⁠ or compatible data streams prior to invoking the ZIP compression routine.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions