Just learned about ffprobe yesterday, and I was able, after much googling, to assemble a command line BAT file to get the meta info I want. Then, it turns out that it only works about half the time. After some experimentation, it seems that it's working only on MKV files.
I don't know if there's a bug going on here, or if my command line needs improvement. Maybe ffProbe only works on certain files, but I was assuming it would work on most popular vid formats.
I'm using AutoHotKey to create a BAT file, which I then launch. So we really just need to look at the BAT file.
Here's my BAT script...
C:\PROGRA~1\ffmpeg\bin\ffprobe.exe -pretty -select_streams v \
-show_entries \
format=filename,size,duration,bit_rate:stream=codec_name,codec_type,bit_rate,width,height,display_aspect_ratio \
-of ini \
"S:\myTVshows\SampleName - S01E01 - SampleTitle.mp4"
After this is run, the console outputs only the #ffprobe output
header and then hangs. If it runs on an mkv file, then it instantly outputs all the data I want, as expected.
Update: when I add -report
as a parameter, I get the report log file, of course... but I also get the output I want (instead of it hanging as before). I wonder if it means this is a bug.
Notes
- I reduced the path for ffprobe to 8.3 format so I wouldn't have to worry about quotes around that part.
- I'm working with a very current install of ffmpeg/ffprobe (ffmpeg-20170404-1229007-win64-static).
Below is the console outupt...
ffprobe version N-85266-g1229007 Copyright (c) 2007-2017 the FFmpeg developers
built with gcc 6.3.0 (GCC)
configuration: --enable-gpl --enable-version3 --enable-cuda --enable-cuvid --e
nable-d3d11va --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --
enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv
--enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-li
bfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug -
-enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enabl
e-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-li
bsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolam
e --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx
--enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable
-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-zlib
libavutil 55. 59.100 / 55. 59.100
libavcodec 57. 90.100 / 57. 90.100
libavformat 57. 72.100 / 57. 72.100
libavdevice 57. 7.100 / 57. 7.100
libavfilter 6. 83.100 / 6. 83.100
libswscale 4. 7.100 / 4. 7.100
libswresample 2. 8.100 / 2. 8.100
libpostproc 54. 6.100 / 54. 6.100
# ffprobe output
report
to the command and run. Share the report file.-report
was added