immich-app / immich

High performance self-hosted photo and video management solution.
https://immich.app
GNU Affero General Public License v3.0
44.56k stars 2.17k forks source link

[BUG] Sony RAW (.ARW) unsupported #2156

Closed uhthomas closed 1 year ago

uhthomas commented 1 year ago

The bug

I found https://github.com/immich-app/immich/issues/1109, but do not believe the resolution is fair. The Sony RAW format is very popular and is a major blocker for adoption.

The linked libvips issue suggests there is support for the file format, but magickload must be used instead.

The OS that Immich Server is running on

N/A

Version of Immich Server

v1.52.1

Version of Immich Mobile App

N/A

Platform with the issue

Your docker-compose.yml content

N/A

Your .env content

N/A

Reproduction steps

N/A

Additional information

N/A

samip5 commented 1 year ago

Could I have an example file to test with?

andrewgdunn commented 1 year ago

Here is a link to an example JPG and RAW file: https://photos.app.goo.gl/fxjPFHKZ274LR6c17

samip5 commented 1 year ago

Here is a link to an example JPG and RAW file: https://photos.app.goo.gl/fxjPFHKZ274LR6c17

Unfortunately, Google Photos will not let me download the .ARW file. Those both come downloaded as JPEG.

uhthomas commented 1 year ago

@samip5 Please see this ARW image: https://github.com/uhthomas/immich2156/blob/main/_DSC2642.ARW (direct download link: https://github.com/uhthomas/immich2156/raw/main/_DSC2642.ARW).

uhthomas commented 1 year ago

So I've been looking into this and I think it should actually be a really small change, though I did come across a major caveat. Image Magick on Alpine is compiled for ufraw, which is not a valid package on Alpine. The base image may need to use debian instead, at least until the upstream issue is fixed.

See https://gitlab.alpinelinux.org/alpine/aports/-/issues/14957.

jrasm91 commented 1 year ago

Just FYI - On my backlog is to finish #2198, which is trying to integrate darktable-cli which has general support for many different raw formats.

uhthomas commented 1 year ago

Just FYI - On my backlog is to finish #2198, which is trying to integrate darktable-cli which has general support for many different raw formats.

I wouldn't worry about it. It looks like the alpine authors have already recompiled imagemagick with libraw support. The change for Immich is then just including that package. I think this is preferable to relying on multiple cli tools and keeps the code cleaner. The change should also be less risky.

jrasm91 commented 1 year ago

What does this imply? Will this change add general support for RAW files? If so, I agree that would be preferable.

uhthomas commented 1 year ago

I believe it does, yes. It should support: https://www.libraw.org/supported-cameras.

jrasm91 commented 1 year ago

Great, I'll keep putting it off then :laughing: and maybe it will resolve itself.