[FFmpeg-user] XSLT for ffprobe-XML to METS conversion
daverice at mac.com
Wed Aug 8 01:01:06 CEST 2012
On Aug 7, 2012, at 9:41 AM, Peter B. wrote:
> I've took the time to write a quick "ffmpeg2mets.xsl" stylesheet, which transforms the technical metadata from ffprobe's XML output into a standardized structure for audio/video as defined by the U.S. Libary of Congress , and stored in a METS container XML .
> Duration is stored in ISO8601 format , bitrate in kbps and samplerate in kHz.
> It's no big thing, and also not very robust or pimped, but I thought I'd post it in case someone could need it, too:
Thanks for sharing this. I was just considering doing this myself. By the way, I drafted up a ffprobe-XML to PREMIS metadata transformation (here: https://gist.github.com/3290340), but see that METS may be more useful. With the ffprobe2premis.xsl file you can apply it with:
ffprobe -show_format -show_streams -show_versions -show_error -noprivate -print_format xml=q=1:x=1 MOVIE.mov 2>/dev/null | xsltproc ffprobe2premis.xsl
More information about the ffmpeg-user