Browse Source

sws: disable scale16 when int32 is used

tags/n0.9
Michael Niedermayer 14 years ago
parent
commit
ca78fa24b7
2 changed files with 6 additions and 3 deletions
  1. +3
    -2
      libswscale/swscale.c
  2. +3
    -1
      libswscale/x86/swscale_template.c

+ 3
- 2
libswscale/swscale.c View File

@@ -2881,8 +2881,8 @@ static av_cold void sws_init_swScale_c(SwsContext *c)
}
}

if(((isAnyRGB(c->srcFormat) && av_pix_fmt_descriptors[c->srcFormat].comp[0].depth_minus1<15)
|| c->srcFormat == PIX_FMT_PAL8) && c->scalingBpp == 8)
if((isAnyRGB(c->srcFormat) && av_pix_fmt_descriptors[c->srcFormat].comp[0].depth_minus1<15)
|| c->srcFormat == PIX_FMT_PAL8)
c->hScale16= hScale16N_c;

if (c->scalingBpp == 8) {
@@ -2902,6 +2902,7 @@ static av_cold void sws_init_swScale_c(SwsContext *c)
}
}
} else {
c->hScale16 = NULL;
c->hScale = hScale16_c;
c->scale19To15Fw = scale19To15Fw_c;
c->scale8To16Rv = scale8To16Rv_c;


+ 3
- 1
libswscale/x86/swscale_template.c View File

@@ -2438,6 +2438,8 @@ static av_cold void RENAME(sws_init_swScale)(SwsContext *c)
}
}
#endif /* !COMPILE_TEMPLATE_MMX2 */
if(isAnyRGB(c->srcFormat) && av_pix_fmt_descriptors[c->srcFormat].comp[0].depth_minus1<15 && c->scalingBpp == 8)
if(isAnyRGB(c->srcFormat) && av_pix_fmt_descriptors[c->srcFormat].comp[0].depth_minus1<15)
c->hScale16= RENAME(hScale16);
if(c->scalingBpp != 8)
c->hScale16 = NULL;
}

Loading…
Cancel
Save