码迷,mamicode.com
首页 > Web开发 > 详细

ffprobe读取音视频元数据信息,json格式输出

时间:2019-09-02 09:47:56      阅读:785      评论:0      收藏:0      [点我收藏+]

标签:rate   red   ogr   ase   effect   com   span   signed   tle   

命令格式:

ffprobe -v quiet -show_format -show_streams -print_format json F:\temp\test1566606924822.wav

输出

{
    "streams": [
        {
            "index": 0,
            "codec_name": "pcm_s16le",
            "codec_long_name": "PCM signed 16-bit little-endian",
            "codec_type": "audio",
            "codec_time_base": "1/8000",
            "codec_tag_string": "[1][0][0][0]",
            "codec_tag": "0x0001",
            "sample_fmt": "s16",
            "sample_rate": "8000",
            "channels": 1,
            "bits_per_sample": 16,
            "r_frame_rate": "0/0",
            "avg_frame_rate": "0/0",
            "time_base": "1/8000",
            "duration_ts": 1710489,
            "duration": "213.811125",
            "bit_rate": "128000",
            "disposition": {
                "default": 0,
                "dub": 0,
                "original": 0,
                "comment": 0,
                "lyrics": 0,
                "karaoke": 0,
                "forced": 0,
                "hearing_impaired": 0,
                "visual_impaired": 0,
                "clean_effects": 0,
                "attached_pic": 0,
                "timed_thumbnails": 0
            }
        }
    ],
    "format": {
        "filename": "F:\\temp\\test1566606924822.wav",
        "nb_streams": 1,
        "nb_programs": 0,
        "format_name": "wav",
        "format_long_name": "WAV / WAVE (Waveform Audio)",
        "duration": "213.811125",
        "size": "3421022",
        "bit_rate": "128001",
        "probe_score": 99
    }
}

 

ffprobe读取音视频元数据信息,json格式输出

标签:rate   red   ogr   ase   effect   com   span   signed   tle   

原文地址:https://www.cnblogs.com/passedbylove/p/11444566.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!