photoprism/pkg/live
Michael Mayer a0904c4008 Docs: Update pkg/live/README.md and pkg/video/README.md
Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-10-05 09:37:25 +02:00
..
live.go Index: Add native support for MP4 and Samsung/Google Motion Photos #439 2023-09-22 23:59:56 +02:00
README.md Docs: Update pkg/live/README.md and pkg/video/README.md 2023-10-05 09:37:25 +02:00

Hybrid Photo/Video File Support

Apple iPhone and iPad

iOS Live Photos consist of a JPEG/HEIC image and a QuickTime AVC/HEVC video, which are both required for viewing.

We recommend using an app like PhotoSync to upload Live Photos to PhotoPrism, since the iOS web upload usually only submits the HEIC image file without the video.

Android Devices

Some Samsung and Google Android devices support taking "Motion Photos" with the included Camera app. Motion Photos are JPEG/HEIC image with a short MP4 video embedded after the image data.

The image part of these files can be opened in any image viewer that supports JPEG/HEIC, but the video part cannot. However, since the MP4 video is simply appended at the end of the image file, it can be easily read by our software and streamed through the API as needed.

Introductory Tutorials

Title Date URL
How to detect Android motion photos in Flutter May 2023 https://ente.io/blog/tech/android-motion-photos-flutter/
Stripping Embedded MP4s out of Android 12 Motion Photos Oct 2021 https://mjanja.ch/2021/10/stripping-embedded-mp4s-out-of-android-12-motion-photos/
Google Pixel "Motion Photo" Howto Mar 2021 https://linuxreviews.org/Google_Pixel_%22Motion_Photo%22
go-mp4: Golang Library and CLI Tool for MP4 Jul 2020 https://dev.to/sunfishshogi/go-mp4-golang-library-and-cli-tool-for-mp4-52o1
Working with Motion Photos Jan 2019 https://medium.com/android-news/working-with-motion-photos-da0aa49b50c
Google: Behind the Motion Photos Technology in Pixel 2 Mar 2018 https://blog.research.google/2018/03/behind-motion-photos-technology-in.html

Software Libraries and References

Title URL
Web Video Codec Guide https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Video_codecs
Media Container Formats https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Containers
MP4 Signature Format https://www.file-recovery.com/mp4-signature-format.htm
List of file signatures (Wikipedia) https://en.wikipedia.org/wiki/List_of_file_signatures
Go library for reading and writing MP4 files https://github.com/abema/go-mp4
Go library for buffered I/O with io.Seeker interface https://github.com/sunfish-shogi/bufseekio
How to use the io.Reader interface https://yourbasic.org/golang/io-reader-interface-explained/
AV1 Codec ISO Media File Format https://aomediacodec.github.io/av1-isobmff

PhotoPrism® is a registered trademark. By using the software and services we provide, you agree to our Terms of Service, Privacy Policy, and Code of Conduct. Docs are available under the CC BY-NC-SA 4.0 License; additional terms may apply.