diff --git a/recording-daemon/decoder.c b/recording-daemon/decoder.c index 291a4d7d1..b32c799f7 100644 --- a/recording-daemon/decoder.c +++ b/recording-daemon/decoder.c @@ -247,7 +247,7 @@ int decoder_input(decoder_t *dec, const str *data, unsigned long ts, output_t *o keep_going = 0; int got_frame = 0; -#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 0, 0) +#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 36, 0) if (dec->avpkt.size) { int ret = avcodec_send_packet(dec->avcctx, &dec->avpkt); dbg("send packet ret %i", ret); @@ -303,7 +303,7 @@ int decoder_input(decoder_t *dec, const str *data, unsigned long ts, output_t *o #endif if (got_frame) { -#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(57, 0, 0) +#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(57, 36, 0) dec->frame->pts = dec->frame->pkt_pts; #endif if (G_UNLIKELY(dec->frame->pts == AV_NOPTS_VALUE)) diff --git a/recording-daemon/output.c b/recording-daemon/output.c index 71636a514..5ecb18969 100644 --- a/recording-daemon/output.c +++ b/recording-daemon/output.c @@ -35,7 +35,7 @@ static int output_flush(output_t *output) { keep_going = 0; int got_packet = 0; -#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 0, 0) +#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 36, 0) if (have_frame) { int ret = avcodec_send_frame(output->avcctx, output->frame); dbg("%p send frame ret %i", output, ret); @@ -197,7 +197,7 @@ int output_config(output_t *output, const format_t *requested_format, format_t * output->avcctx->bit_rate = mp3_bitrate; output->avst->time_base = output->avcctx->time_base; -#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57, 0, 0) +#if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(57, 26, 0) // exact version? present in 57.56 avcodec_parameters_from_context(output->avst->codecpar, output->avcctx); #endif