mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-27 09:52:17 +00:00
avcodec/internal, avfilter/qp_table: Remove unused FF_QSCALE_TYPEs
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
b1cbeabf5e
commit
e142153bd7
@ -37,8 +37,6 @@
|
||||
|
||||
#define FF_QSCALE_TYPE_MPEG1 0
|
||||
#define FF_QSCALE_TYPE_MPEG2 1
|
||||
#define FF_QSCALE_TYPE_H264 2
|
||||
#define FF_QSCALE_TYPE_VP56 3
|
||||
|
||||
#define FF_SANE_NB_CHANNELS 512U
|
||||
|
||||
|
@ -33,16 +33,12 @@ int ff_qp_table_extract(AVFrame *frame, int8_t **table, int *table_w, int *table
|
||||
|
||||
/**
|
||||
* Normalize the qscale factor
|
||||
* FIXME the H264 qscale is a log based scale, mpeg1/2 is not, the code below
|
||||
* cannot be optimal
|
||||
*/
|
||||
static inline int ff_norm_qscale(int qscale, int type)
|
||||
{
|
||||
switch (type) {
|
||||
case FF_QSCALE_TYPE_MPEG1: return qscale;
|
||||
case FF_QSCALE_TYPE_MPEG2: return qscale >> 1;
|
||||
case FF_QSCALE_TYPE_H264: return qscale >> 2;
|
||||
case FF_QSCALE_TYPE_VP56: return (63 - qscale + 2) >> 2;
|
||||
}
|
||||
return qscale;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user