Browse Source

dsputil: Remove dct_bits

dct_bits is never set except in h264, where it is never used,
thus remove it.

Signed-off-by: Martin Storsjö <martin@martin.st>
tags/n2.0
Ronald S. Bultje Martin Storsjö 12 years ago
parent
commit
c443117f25
3 changed files with 2 additions and 16 deletions
  1. +2
    -10
      libavcodec/dsputil.c
  2. +0
    -5
      libavcodec/dsputil.h
  3. +0
    -1
      libavcodec/h264.c

+ 2
- 10
libavcodec/dsputil.c View File

@@ -2736,18 +2736,10 @@ av_cold void ff_dsputil_init(DSPContext* c, AVCodecContext *avctx)

switch (avctx->bits_per_raw_sample) {
case 9:
if (c->dct_bits == 32) {
BIT_DEPTH_FUNCS(9, _32);
} else {
BIT_DEPTH_FUNCS(9, _16);
}
BIT_DEPTH_FUNCS(9, _16);
break;
case 10:
if (c->dct_bits == 32) {
BIT_DEPTH_FUNCS(10, _32);
} else {
BIT_DEPTH_FUNCS(10, _16);
}
BIT_DEPTH_FUNCS(10, _16);
break;
default:
BIT_DEPTH_FUNCS(8, _16);


+ 0
- 5
libavcodec/dsputil.h View File

@@ -125,11 +125,6 @@ void ff_init_scantable_permutation(uint8_t *idct_permutation,
* DSPContext.
*/
typedef struct DSPContext {
/**
* Size of DCT coefficients.
*/
int dct_bits;

/* pixel ops : interface with DCT */
void (*get_pixels)(int16_t *block/*align 16*/, const uint8_t *pixels/*align 8*/, int line_size);
void (*diff_pixels)(int16_t *block/*align 16*/, const uint8_t *s1/*align 8*/, const uint8_t *s2/*align 8*/, int stride);


+ 0
- 1
libavcodec/h264.c View File

@@ -2912,7 +2912,6 @@ static int h264_set_parameter_from_sps(H264Context *h)
ff_h264qpel_init(&h->h264qpel, h->sps.bit_depth_luma);
ff_h264_pred_init(&h->hpc, h->avctx->codec_id, h->sps.bit_depth_luma,
h->sps.chroma_format_idc);
h->dsp.dct_bits = h->sps.bit_depth_luma > 8 ? 32 : 16;
if (CONFIG_ERROR_RESILIENCE)
ff_dsputil_init(&h->dsp, h->avctx);
ff_videodsp_init(&h->vdsp, h->sps.bit_depth_luma);


Loading…
Cancel
Save