Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Metadata reading/saving needs to handle images and videos #284

Open
bruvellu opened this issue Jan 20, 2024 · 0 comments
Open

Metadata reading/saving needs to handle images and videos #284

bruvellu opened this issue Jan 20, 2024 · 0 comments
Assignees
Labels
bug Issues with bugs that need to be fixed

Comments

@bruvellu
Copy link
Owner

Metadata reading and saving is only working for images. If the media is a video, an InvalidImageDataError error occurs when trying to write the metadata. I have a few suggestions regarding metadata handling:

  • Don't write metadata to the original file: Because uploaded files can be a PNG or GIF which don't handle metadata as JPG, or they can be MP4 videos, I propose we do not write the metadata to the original uploaded file. Just read the metadata during upload and never modify it again.
  • Write metadata to every file size: After the file fields were standardized in Standardize file fields in Media models #276, the metadata should be written to all of them.
  • Handle video metadata reading and writing: I know that FFmpeg can pass -metadata arguments when processing. This can be a way to write the metadata to the file (although it'll be time-consuming). I took a brief look and found an IPTC standard for video metadata. Not sure if there's any library to read/write.
@bruvellu bruvellu added the bug Issues with bugs that need to be fixed label Jan 20, 2024
@bruvellu bruvellu self-assigned this Dec 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issues with bugs that need to be fixed
Projects
None yet
Development

No branches or pull requests

1 participant