]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/pamenc.c
avcodec/vdpau_hevc: Properly signal the num_delta_pocs from the SPS RPS
[ffmpeg] / libavcodec / pamenc.c
index b361380ff69eba3cc99b6a398cc3096ab71f6c6a..50c9fcb4046f69dab43bbdc5dd7e5e5b9e8073ee 100644 (file)
@@ -91,7 +91,7 @@ static int pam_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
         return -1;
     }
 
-    if ((ret = ff_alloc_packet2(avctx, pkt, n*h + 200)) < 0)
+    if ((ret = ff_alloc_packet2(avctx, pkt, n*h + 200, 0)) < 0)
         return ret;
 
     bytestream_start =
@@ -129,8 +129,12 @@ static int pam_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
 
 static av_cold int pam_encode_init(AVCodecContext *avctx)
 {
+#if FF_API_CODED_FRAME
+FF_DISABLE_DEPRECATION_WARNINGS
     avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I;
     avctx->coded_frame->key_frame = 1;
+FF_ENABLE_DEPRECATION_WARNINGS
+#endif
 
     return 0;
 }