comparison bfin/dsputil_bfin.c @ 9726:28796439526a libavcodec

blackfin: use optimised (I)DCT only when ctx->(i)dct_algo is auto
author mru
date Thu, 28 May 2009 22:35:58 +0000
parents cf4d575b1982
children e07a0d71fba9
comparison
equal deleted inserted replaced
9725:4b63d4691d4a 9726:28796439526a
291 c->put_no_rnd_pixels_tab[0][0] = bfin_put_pixels16_nornd; 291 c->put_no_rnd_pixels_tab[0][0] = bfin_put_pixels16_nornd;
292 c->put_no_rnd_pixels_tab[0][1] = bfin_put_pixels16_x2_nornd; 292 c->put_no_rnd_pixels_tab[0][1] = bfin_put_pixels16_x2_nornd;
293 c->put_no_rnd_pixels_tab[0][2] = bfin_put_pixels16_y2_nornd; 293 c->put_no_rnd_pixels_tab[0][2] = bfin_put_pixels16_y2_nornd;
294 c->put_no_rnd_pixels_tab[0][3] = ff_bfin_put_pixels16_xy2_nornd; 294 c->put_no_rnd_pixels_tab[0][3] = ff_bfin_put_pixels16_xy2_nornd;
295 295
296 c->idct_permutation_type = FF_NO_IDCT_PERM; 296 if (avctx->dct_algo == FF_DCT_AUTO)
297 c->fdct = ff_bfin_fdct; 297 c->fdct = ff_bfin_fdct;
298
298 if (avctx->idct_algo==FF_IDCT_VP3) { 299 if (avctx->idct_algo==FF_IDCT_VP3) {
300 c->idct_permutation_type = FF_NO_IDCT_PERM;
299 c->idct = ff_bfin_vp3_idct; 301 c->idct = ff_bfin_vp3_idct;
300 c->idct_add = ff_bfin_vp3_idct_add; 302 c->idct_add = ff_bfin_vp3_idct_add;
301 c->idct_put = ff_bfin_vp3_idct_put; 303 c->idct_put = ff_bfin_vp3_idct_put;
302 } else { 304 } else if (avctx->idct_algo == FF_IDCT_AUTO) {
305 c->idct_permutation_type = FF_NO_IDCT_PERM;
303 c->idct = ff_bfin_idct; 306 c->idct = ff_bfin_idct;
304 c->idct_add = bfin_idct_add; 307 c->idct_add = bfin_idct_add;
305 c->idct_put = bfin_idct_put; 308 c->idct_put = bfin_idct_put;
306 } 309 }
307 } 310 }