2

I'm trying to create a json file with information of a mp4 file with avprobe, but it doesn't print nothing.

The command

avprobe -v 0 -show_format -of json myvideo.mp4

My avprobe version

avprobe version 0.8.6-6:0.8.6-1ubuntu2, Copyright (c) 2007-2013 the Libav developers
  built on Mar 30 2013 22:20:06 with gcc 4.7.2
avprobe 0.8.6-6:0.8.6-1ubuntu2
libavutil    51. 22. 1 / 51. 22. 1
libavcodec   53. 35. 0 / 53. 35. 0
libavformat  53. 21. 1 / 53. 21. 1
libavdevice  53.  2. 0 / 53.  2. 0
libavfilter   2. 15. 0 /  2. 15. 0
libswscale    2.  1. 0 /  2.  1. 0
libpostproc  52.  0. 0 / 52.  0. 0

This

avprobe -v 0 -show_format -show_streams myvideo.mp4

shows me some the video information in a ini format.

PJunior
  • 335
  • 1
  • 3
  • 13
  • I don't use avprobe (I use the rival ffmpeg), but it's quite likely that the version in the Ubuntu repos is out of date (it's a pretty fast-moving project). Check the avprobe man page on your local system for accurate documentation. – evilsoup Sep 19 '13 at 15:38
  • Yes! I was using ffmpeg and was working perfectly! :) ffprobe -v quiet -print_format json -show_format -show_streams source.mp4 > file.json But since I got the warning that ffmpeg was deprecated I'v switched to avconv. – PJunior Sep 19 '13 at 20:13
  • I believe "-of json" option is available since version 9 of libav – jfburdet Mar 02 '14 at 11:34

1 Answers1

1

The following works for me :

avprobe -v 0 -show_format -show_streams myvideo.mp4 -of json

I'm using libav-tools version 6:11.2-1~ppa1 on Ubuntu.

Hope this helps.

Sebastien.

SebMa
  • 2,291