[FFmpeg-cvslog] Add some more deprecation guards
Diego Biurrun
git at videolan.org
Wed Jun 22 11:05:58 CEST 2016
ffmpeg | branch: master | Diego Biurrun <diego at biurrun.de> | Wed May 4 00:27:19 2016 +0200| [763d69bfb2f0094e99f43e657cfd2b0471361f6b] | committer: Diego Biurrun
Add some more deprecation guards
Avoids unused function/label/variable warnings after the next version bump.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=763d69bfb2f0094e99f43e657cfd2b0471361f6b
---
avconv.c | 2 ++
libavcodec/error_resilience.c | 2 ++
libavcodec/qtrleenc.c | 6 ++++++
3 files changed, 10 insertions(+)
diff --git a/avconv.c b/avconv.c
index 3b61ee2..74459ab 100644
--- a/avconv.c
+++ b/avconv.c
@@ -569,10 +569,12 @@ error:
exit_program(1);
}
+#if FF_API_CODED_FRAME
static double psnr(double d)
{
return -10.0 * log(d) / log(10.0);
}
+#endif
static void do_video_stats(OutputStream *ost, int frame_size)
{
diff --git a/libavcodec/error_resilience.c b/libavcodec/error_resilience.c
index eb6fd14..d53dfdd 100644
--- a/libavcodec/error_resilience.c
+++ b/libavcodec/error_resilience.c
@@ -1199,7 +1199,9 @@ FF_ENABLE_DEPRECATION_WARNINGS
s->mb_height, linesize[2], 0);
}
+#if FF_API_XVMC
ec_clean:
+#endif
/* clean a few tables */
for (i = 0; i < s->mb_num; i++) {
const int mb_xy = s->mb_index2xy[i];
diff --git a/libavcodec/qtrleenc.c b/libavcodec/qtrleenc.c
index 67c88e1..e7de209 100644
--- a/libavcodec/qtrleenc.c
+++ b/libavcodec/qtrleenc.c
@@ -297,7 +297,9 @@ static int qtrle_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
const AVFrame *pict, int *got_packet)
{
QtrleEncContext * const s = avctx->priv_data;
+#if FF_API_CODED_FRAME
enum AVPictureType pict_type;
+#endif
int ret;
if ((ret = ff_alloc_packet(pkt, s->max_buf_size)) < 0) {
@@ -308,11 +310,15 @@ static int qtrle_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
if (avctx->gop_size == 0 || (s->avctx->frame_number % avctx->gop_size) == 0) {
/* I-Frame */
+#if FF_API_CODED_FRAME
pict_type = AV_PICTURE_TYPE_I;
+#endif
s->key_frame = 1;
} else {
/* P-Frame */
+#if FF_API_CODED_FRAME
pict_type = AV_PICTURE_TYPE_P;
+#endif
s->key_frame = 0;
}
More information about the ffmpeg-cvslog
mailing list