diff options
author | Timothy Gu <timothygu99@gmail.com> | 2016-02-03 03:53:28 +0300 |
---|---|---|
committer | Timothy Gu <timothygu99@gmail.com> | 2016-02-07 20:09:13 +0300 |
commit | 6cdde20beb9801ab83f142b56449e0a3f69b4019 (patch) | |
tree | d28d47d47e233ef6985b9d8891ba1516e3e111ec /libavcodec/dirac_dwt_template.c | |
parent | 6c0318c4ba8e749911324d96e7c04fcc04661c97 (diff) |
dirac_dwt: Don't pass information in context as arguments
Diffstat (limited to 'libavcodec/dirac_dwt_template.c')
-rw-r--r-- | libavcodec/dirac_dwt_template.c | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/libavcodec/dirac_dwt_template.c b/libavcodec/dirac_dwt_template.c index dfcf1de0e8..de17a2d536 100644 --- a/libavcodec/dirac_dwt_template.c +++ b/libavcodec/dirac_dwt_template.c @@ -516,39 +516,32 @@ static void RENAME(spatial_compose_dd137i_init)(DWTCompose *cs, uint8_t *buffer, cs->y = -5; } -static int RENAME(ff_spatial_idwt_init2)(DWTContext *d, uint8_t *buffer, int width, int height, - int stride, enum dwt_type type, int decomposition_count, - uint8_t *temp) +static int RENAME(ff_spatial_idwt_init2)(DWTContext *d, enum dwt_type type) { int level; - d->buffer = buffer; - d->width = width; - d->height = height; - d->stride = stride; - d->decomposition_count = decomposition_count; - d->temp = (uint8_t *)(((TYPE *)temp) + 8); + d->temp = (uint8_t *)(((TYPE *)d->temp) + 8); - for(level=decomposition_count-1; level>=0; level--){ - int hl = height >> level; - int stride_l = stride << level; + for (level = d->decomposition_count - 1; level >= 0; level--){ + int hl = d->height >> level; + int stride_l = d->stride << level; switch(type){ case DWT_DIRAC_DD9_7: - RENAME(spatial_compose_dd97i_init)(d->cs+level, buffer, hl, stride_l); + RENAME(spatial_compose_dd97i_init)(d->cs+level, d->buffer, hl, stride_l); break; case DWT_DIRAC_LEGALL5_3: - RENAME(spatial_compose53i_init2)(d->cs+level, buffer, hl, stride_l); + RENAME(spatial_compose53i_init2)(d->cs+level, d->buffer, hl, stride_l); break; case DWT_DIRAC_DD13_7: - RENAME(spatial_compose_dd137i_init)(d->cs+level, buffer, hl, stride_l); + RENAME(spatial_compose_dd137i_init)(d->cs+level, d->buffer, hl, stride_l); break; case DWT_DIRAC_HAAR0: case DWT_DIRAC_HAAR1: d->cs[level].y = 1; break; case DWT_DIRAC_DAUB9_7: - RENAME(spatial_compose97i_init2)(d->cs+level, buffer, hl, stride_l); + RENAME(spatial_compose97i_init2)(d->cs+level, d->buffer, hl, stride_l); break; default: d->cs[level].y = 0; |