ffmpeg/libav conditions for CodecID and AVCODEC_MAX_AUDIO_FRAME_SIZE (thanks @freultwah)

This commit is contained in:
ejurgensen
2014-01-27 21:24:08 +01:00
parent 6decdf4eaf
commit 785383861b
2 changed files with 11 additions and 1 deletions

View File

@@ -55,7 +55,11 @@
#include "transcode.h"
#define XCODE_BUFFER_SIZE ((AVCODEC_MAX_AUDIO_FRAME_SIZE * 3) / 2)
#if LIBAVCODEC_VERSION_MAJOR >= 56 || (LIBAVCODEC_VERSION_MAJOR == 55 && LIBAVCODEC_VERSION_MINOR >= 18)
# define XCODE_BUFFER_SIZE ((192000 * 3) / 2)
#else
# define XCODE_BUFFER_SIZE ((AVCODEC_MAX_AUDIO_FRAME_SIZE * 3) / 2)
#endif
struct transcode_ctx {