EXIF like thing for Videos

可紊 提交于 2019-12-22 10:54:00

问题


Is there any standard way to get information from a video file? For images we have EXIF data which can be used to get information about the date/time , size etc of the image file. I was wondering if there is such a thing for videos as well.

The use case is - I have lot of videos which I shot from my digital camera. I want to rename them to something more meaningful like YYYY-MM-DD rather than Video_N . The YYYY-MM-DD should be the date and time when the video was shot.

Any solution in Python, C/C++, Perl would be appreciated but if you have solution in other language, please do let me know.

Thanks.


回答1:


exiftool reads video containers and their metadata.




回答2:


Unfortunately, most cameras don't actually store enough metadata in the video :(.

If they are storing it, due to the wide variety of video codecs and containers like AVI, MOV, MPG, MP4, etc., a good option will to run ffmpeg -i to read it.



来源:https://stackoverflow.com/questions/6248347/exif-like-thing-for-videos

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!