Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -381,17 +381,17 @@ for dir in "" /usr/local $SEARCH_DIR; do
if test -n "$dir"; then
LDFLAGS="$LDFLAGS -L$dir/lib"
fi
AC_CHECK_LIB([avformat], [av_open_input_file], [LIBAVFORMAT_LIBS="-lavformat"], [unset ac_cv_lib_avformat_av_open_input_file; LDFLAGS="$LDFLAGS_SAVE"; continue])
AC_CHECK_LIB([avformat], [avformat_open_input], [LIBAVFORMAT_LIBS="-lavformat"], [unset ac_cv_lib_avformat_avformat_open_input; LDFLAGS="$LDFLAGS_SAVE"; continue])
AC_SUBST(LIBJPEG_LIBS)
break
done
test x"$ac_cv_lib_avformat_av_open_input_file" = x"yes" || AC_MSG_ERROR([Could not find libavformat - part of ffmpeg])
test x"$ac_cv_lib_avformat_avformat_open_input" = x"yes" || AC_MSG_ERROR([Could not find libavformat - part of ffmpeg])
AC_SUBST(LIBAVFORMAT_LIBS)

AC_CHECK_LIB(avutil ,[av_rescale_q], [LIBAVUTIL_LIBS="-lavutil"], [AC_MSG_ERROR([Could not find libavutil - part of ffmpeg])])
AC_SUBST(LIBAVUTIL_LIBS)

AC_CHECK_LIB(avcodec ,[avcodec_init], [LIBAVCODEC_LIBS="-lavcodec"], [AC_MSG_ERROR([Could not find libavcodec - part of ffmpeg])])
AC_CHECK_LIB(avcodec ,[avcodec_register], [LIBAVCODEC_LIBS="-lavcodec"], [AC_MSG_ERROR([Could not find libavcodec - part of ffmpeg])])
AC_SUBST(LIBAVCODEC_LIBS)

AC_CHECK_LIB(pthread, pthread_create)
Expand Down
10 changes: 5 additions & 5 deletions metadata.c
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,7 @@ GetVideoMetadata(const char * path, char * name)
DPRINTF(E_WARN, L_METADATA, "Opening %s failed!\n", path);
return 0;
}
av_find_stream_info(ctx);
avformat_find_stream_info(ctx, NULL);
//dump_format(ctx, 0, NULL, 0);
for( i=0; i<ctx->nb_streams; i++)
{
Expand All @@ -772,7 +772,7 @@ GetVideoMetadata(const char * path, char * name)
if( !vc )
{
/* This must not be a video file. */
av_close_input_file(ctx);
avformat_close_input(&ctx);
if( !is_audio(path) )
DPRINTF(E_DEBUG, L_METADATA, "File %s does not contain a video stream.\n", basepath);
free(path_cpy);
Expand Down Expand Up @@ -1555,10 +1555,10 @@ GetVideoMetadata(const char * path, char * name)
{
if( ctx->metadata )
{
AVMetadataTag *tag = NULL;
AVDictionaryEntry *tag = NULL;

//DEBUG DPRINTF(E_DEBUG, L_METADATA, "Metadata:\n");
while( (tag = av_metadata_get(ctx->metadata, "", tag, AV_METADATA_IGNORE_SUFFIX)) )
while( (tag = av_dict_get(ctx->metadata, "", tag, AV_DICT_IGNORE_SUFFIX)) )
{
//DEBUG DPRINTF(E_DEBUG, L_METADATA, " %-16s: %s\n", tag->key, tag->value);
if( strcmp(tag->key, "title") == 0 )
Expand All @@ -1575,7 +1575,7 @@ GetVideoMetadata(const char * path, char * name)
#endif
#endif
video_no_dlna:
av_close_input_file(ctx);
avformat_close_input(&ctx);

#ifdef TIVO_SUPPORT
if( ends_with(path, ".TiVo") && is_tivo_file(path) )
Expand Down