]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/libopenh264enc.c
avformat/dashdec: remove unused functions and process code
[ffmpeg] / libavcodec / libopenh264enc.c
index fdadb101f513a369bf121701361a325c5e41f3bc..83c3f0ce208cbee1c09a580d74898e0ebb805438 100644 (file)
@@ -246,6 +246,10 @@ static int svc_encode_frame(AVCodecContext *avctx, AVPacket *avpkt,
     sp.iPicWidth  = avctx->width;
     sp.iPicHeight = avctx->height;
 
+    if (frame->pict_type == AV_PICTURE_TYPE_I) {
+        (*s->encoder)->ForceIntraFrame(s->encoder, true);
+    }
+
     encoded = (*s->encoder)->EncodeFrame(s->encoder, &sp, &fbi);
     if (encoded != cmResultSuccess) {
         av_log(avctx, AV_LOG_ERROR, "EncodeFrame failed\n");