av_dump_format

/**
 * Print detailed information about the input or output format, such as
 * duration, bitrate, streams, container, programs, metadata, side data,
 * codec and time base.
 *
 * @param ic        the context to analyze
 * @param index     index of the stream to dump information about
 * @param url       the URL to print, such as source or destination file
 * @param is_output Select whether the specified context is an input(0) or output(1)
 */
void av_dump_format(AVFormatContext *ic,
                    int index,
                    const char *url,
                    int is_output);



#include 
#include "libavutil/avutil.h"
#include "libavformat/avformat.h"

int test_av_dump_format()
{
    AVFormatContext *acfctx = NULL;
    avformat_open_input(&acfctx, "test.mp4", NULL, NULL);
    avformat_find_stream_info(acfctx, NULL);
    av_dump_format(acfctx, 0, "test.mp4", 0);

}

int main()
{
    test_av_dump_format();
    printf("Hello World!\n");
    printf("Hello FFMPEG, version is %s\n", av_version_info());
    return 0;
}

av_dump_format_第1张图片

你可能感兴趣的:(c++,开发语言)