]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/proresenc_anatoliy.c
avcodec/dnxhd_parser: remove unneeded code
[ffmpeg] / libavcodec / proresenc_anatoliy.c
index 5914445b52b894141f5a8270e02926b860742c2d..0fc79fc1dead14c99a77e25cfc9aed6b3782e681 100644 (file)
@@ -485,7 +485,7 @@ static inline void subimage_with_fill_template(uint16_t *src, unsigned x, unsign
     } else {
         src_stride = stride; /* 2 lines stride */
         src += y * src_stride + x;
-        box_height = FFMIN(height - y * 2, dst_height);
+        box_height = FFMIN(height/2 - y, dst_height);
         if (!is_top_field)
             src += stride >> 1;
     }
@@ -671,7 +671,7 @@ static int prores_encode_picture(AVCodecContext *avctx, const AVFrame *pic,
             picture_height = avctx->height / 2;
         }
         mb_height = (picture_height + 15) >> 4;
-        unsafe_mb_height_limit = mb_height * 2;
+        unsafe_mb_height_limit = mb_height;
     }
 
     for (i = av_log2(DEFAULT_SLICE_MB_WIDTH); i >= 0; --i) {