Page 1 of 1

QCTools-compatible XML video measurements with FFprobe

Posted: Wed May 20, 2015 10:55 pm
by peter_b
Bay Area Video Coalition's (BAVC) "QCTools" is an amazing piece of software quality control for analogue video source material.

What few know is, that QCTools' analysis algorithms are all implemented directly in FFmpeg's libraries. Therefore, the "FFprobe" commandline tool can be used to generate a QCTools-compatible XML. That XML contains all the video signal measurements which are rendered in QCTools' analysis graphs in the user interface.

*) Syntax described in QCTools's help:
The actual syntax for using ffprobe for generating these XMLs is already described in QCTools' help:

Code: Select all

Help > Data Format
In version 0.7 it says (using FFmpeg version 2.3 or later):

1) For a file with video AND audio named EXAMPLE.mov:

Code: Select all

ffprobe -f lavfi -i "movie=EXAMPLE.mov:s=v+a[in0][in1],[in0]signalstats=stat=tout+vrep+brng,cropdetect=reset=1,split[a][b];[a]field=top[a1];[b]field=bottom[b1],[a1][b1]psnr[out0];[in1]ebur128=metadata=1[out1]" -show_frames -show_versions -of xml=x=1:q=1 -noprivate | gzip > EXAMPLE.mov.qctools.xml.gz
2) For a file with video and NO AUDIO named EXAMPLE.mov:

Code: Select all

ffprobe -f lavfi -i "movie=EXAMPLE.mov,signalstats=stat=tout+vrep+brng,cropdetect=reset=1,split[a][b];[a]field=top[a1];[b]field=bottom[b1],[a1][b1]psnr" -show_frames -show_versions -of xml=x=1:q=1 -noprivate | gzip > EXAMPLE.mov.qctools.xml.gz 
Although QCTools doesn't display the audio graphs yet, you still might want to use the example with audio, so you already have it calculated for future use.
If you store the resulting .qctools.xml.gz file right next to the video with the same name, it will be opened automatically when you load the video in QCTools.

Example:
Videofile: video.mkv
QCTools sidecar XML: video.mkv.qctools.xml.gz

Have fun! :)