]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/mpegvideo_enc.c
avcodec/vdpau: try to fix version macro use
[ffmpeg] / libavcodec / mpegvideo_enc.c
index 3f12e71269e49e17f2cdb2e8460b2fa3085b5f5b..ce010ecf05fbdc03ba7b24be2a412fa5ebf7311c 100644 (file)
@@ -221,6 +221,7 @@ av_cold int ff_dct_encode_init(MpegEncContext *s) {
     if (ARCH_X86)
         ff_dct_encode_init_x86(s);
 
+    ff_h263dsp_init(&s->h263dsp);
     if (!s->dct_quantize)
         s->dct_quantize = ff_dct_quantize_c;
     if (!s->denoise_dct)
@@ -1820,7 +1821,7 @@ static av_always_inline void encode_mb_internal(MpegEncContext *s,
     ptr_cr = s->new_picture.f.data[2] +
              (mb_y * mb_block_height * wrap_c) + mb_x * mb_block_width;
 
-    if((mb_x*16+16 > s->width || mb_y*16+16 > s->height) && s->codec_id != AV_CODEC_ID_AMV){
+    if((mb_x * 16 + 16 > s->width || mb_y * 16 + 16 > s->height) && s->codec_id != AV_CODEC_ID_AMV){
         uint8_t *ebuf = s->edge_emu_buffer + 32;
         int cw = (s->width  + s->chroma_x_shift) >> s->chroma_x_shift;
         int ch = (s->height + s->chroma_y_shift) >> s->chroma_y_shift;
@@ -2572,6 +2573,7 @@ static int encode_thread(AVCodecContext *c, void *arg){
                 if(is_gob_start){
                     if(s->start_mb_y != mb_y || mb_x!=0){
                         write_slice_end(s);
+
                         if(CONFIG_MPEG4_ENCODER && s->codec_id==AV_CODEC_ID_MPEG4 && s->partitioned_frame){
                             ff_mpeg4_init_partitions(s);
                         }