标签:c style class blog code tar
#include "stdafx.h"
#include <stdio.h>
#include <stdlib.h>
extern "C"
{
#include <libavformat/avformat.h>
#include <libavutil/dict.h>
}
#pragma comment(lib, "avformat.lib")
#pragma comment(lib, "avutil.lib")
int main ()
{
AVFormatContext *fmt_ctx = NULL;
AVDictionaryEntry *tag = NULL;
int ret = 0;
av_register_all();
if ((ret = avformat_open_input(&fmt_ctx, "iphone.mp3", NULL, NULL)))
{
return ret;
}
while ((tag = av_dict_get(fmt_ctx->metadata, "", tag, AV_DICT_IGNORE_SUFFIX)))
{
printf("%s=%s\n", tag->key, tag->value);
}
avformat_close_input(&fmt_ctx);
system("pause");
return 0;
}
windows环境下搭建ffmpeg开发环境,布布扣,bubuko.com
标签:c style class blog code tar
原文地址:http://blog.csdn.net/u013085897/article/details/27806667