mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-14 08:15:02 -05:00
Fix a few missing libav conditions
This commit is contained in:
parent
92022d82f7
commit
efd4d56de5
@ -385,12 +385,14 @@ scan_metadata_ffmpeg(char *file, struct media_file_info *mfi)
|
|||||||
#else
|
#else
|
||||||
case CODEC_TYPE_VIDEO:
|
case CODEC_TYPE_VIDEO:
|
||||||
#endif
|
#endif
|
||||||
|
#if LIBAVFORMAT_VERSION_MAJOR >= 55 || (LIBAVFORMAT_VERSION_MAJOR == 54 && LIBAVFORMAT_VERSION_MINOR >= 20)
|
||||||
if (ctx->streams[i]->disposition & AV_DISPOSITION_ATTACHED_PIC)
|
if (ctx->streams[i]->disposition & AV_DISPOSITION_ATTACHED_PIC)
|
||||||
{
|
{
|
||||||
DPRINTF(E_DBG, L_SCAN, "Found embedded artwork (stream %d)\n", i);
|
DPRINTF(E_DBG, L_SCAN, "Found embedded artwork (stream %d)\n", i);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
if (!video_stream)
|
if (!video_stream)
|
||||||
{
|
{
|
||||||
DPRINTF(E_DBG, L_SCAN, "File has video (stream %d)\n", i);
|
DPRINTF(E_DBG, L_SCAN, "File has video (stream %d)\n", i);
|
||||||
|
@ -347,9 +347,12 @@ transcode(struct transcode_ctx *ctx, struct evbuffer *evbuf, int wanted)
|
|||||||
|
|
||||||
ctx->offset += processed;
|
ctx->offset += processed;
|
||||||
|
|
||||||
#if LIBAVCODEC_VERSION_MAJOR >= 54 || (LIBAVCODEC_VERSION_MAJOR == 53 && LIBAVCODEC_VERSION_MINOR >= 35)
|
#if LIBAVCODEC_VERSION_MAJOR >= 55 || (LIBAVCODEC_VERSION_MAJOR == 54 && LIBAVCODEC_VERSION_MINOR >= 35)
|
||||||
if (frame)
|
if (frame)
|
||||||
avcodec_free_frame(&frame);
|
avcodec_free_frame(&frame);
|
||||||
|
#elif LIBAVCODEC_VERSION_MAJOR >= 54 || (LIBAVCODEC_VERSION_MAJOR == 53 && LIBAVCODEC_VERSION_MINOR >= 35)
|
||||||
|
if (frame)
|
||||||
|
av_free(frame);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return processed;
|
return processed;
|
||||||
|
Loading…
Reference in New Issue
Block a user