spieglt / FlyingCarpet

Cross-platform AirDrop. File transfer between Android, iOS, Linux, macOS, and Windows over ad hoc WiFi. No network infrastructure required, just two devices with WiFi chips in close range.
GNU General Public License v3.0
3.42k stars 140 forks source link

ios app don't transfer heif pictures #78

Closed gael-api closed 3 months ago

gael-api commented 3 months ago

Hi, Thanks for this wonderful app! There's an issue with the iOS app v8.0.1 on iOS 17.5.1

Some pictures can't be transferred. I track them down and see that's the HEIF ones. The following message appears in FlyingCarpet : Error: could not get filename from path.

When I choose the most compatible format from the camera roll options, it works like a charm with my Fedora 40 Linux laptop.

spieglt commented 3 months ago

Hmm, sorry to hear that. A friend noticed the same bug with HEIC live photos when the iOS version first came out, so I added a block like:

// if it's a live photo, use the jpeg representation
let fileType = result.itemProvider.hasItemConformingToTypeIdentifier(UTType.heic.identifier)
    ? UTType.jpeg.identifier
    : UTType.item.identifier

I assume I just need the same for UTType.heif.identifier or some such. I'll make an update when I get some time. Thanks for letting me know!

spieglt commented 3 months ago

These are photos, not videos?

gael-api commented 3 months ago

Only the HEIF photos. Videos transfer works well.

spieglt commented 3 months ago

Version 8.0.2 should be available in the App Store, please try updating and let me know.

gael-api commented 3 months ago

With v8.0.2, heif files are correctly converted to jpeg files if Automatic Format is selected in CameraRoll options. But there's still the error if the native format option is choosen.

spieglt commented 3 months ago

Can you please send more information or a screenshot of this setting? I only see this in Camera > Format: image

spieglt commented 3 months ago

Ah, you mean this, when Options is selected after choosing the photos from Camera Roll. Unfortunately I couldn’t get the HEIC/HEIF photos to work, so sending them as JPEGs is the intended workaround. image

gael-api commented 3 months ago

Yes, it's the parameter I was referring to. If HEIF pictures aren't transferable, it's ok for me.