1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

dvenc: fix 2x4x8 (interlaced) weight table

Since the decoder has been fixed to output something similar to
other implementations, the encoder weight table needed this fix.

Reference PSNR values on a progressive sequence (from tiny_psnr)
from a chained encoding and decoding:
Full progressive: stddev:    0.74 PSNR: 50.69 MAXDIFF:   19
Before:           stddev:    1.43 PSNR: 44.97 MAXDIFF:   17
This patch:       stddev:    0.76 PSNR: 50.44 MAXDIFF:   14

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Christophe Gisquet 2015-01-30 19:43:03 +01:00 committed by Michael Niedermayer
parent 2a3b7a55b5
commit cb335b3af2

View File

@ -232,14 +232,14 @@ static const int dv_weight_88[64] = {
170627, 165371, 160727, 153560, 160727, 144651, 144651, 136258,
};
static const int dv_weight_248[64] = {
131072, 242189, 257107, 237536, 229376, 200636, 242189, 223754,
224969, 196781, 262144, 242189, 229376, 200636, 257107, 237536,
211916, 185364, 235923, 217965, 229376, 211916, 206433, 180568,
242189, 223754, 224969, 196781, 211916, 185364, 235923, 217965,
200704, 175557, 222935, 205965, 200636, 185364, 195068, 170627,
229376, 211916, 206433, 180568, 200704, 175557, 222935, 205965,
175557, 153560, 188995, 174609, 165371, 144651, 200636, 185364,
195068, 170627, 175557, 153560, 188995, 174609, 165371, 144651,
131072, 262144, 257107, 257107, 242189, 242189, 242189, 242189,
237536, 237536, 229376, 229376, 200636, 200636, 224973, 224973,
223754, 223754, 235923, 235923, 229376, 229376, 217965, 217965,
211916, 211916, 196781, 196781, 185364, 185364, 206433, 206433,
211916, 211916, 222935, 222935, 200636, 200636, 205964, 205964,
200704, 200704, 180568, 180568, 175557, 175557, 195068, 195068,
185364, 185364, 188995, 188995, 174606, 174606, 175557, 175557,
170627, 170627, 153560, 153560, 165371, 165371, 144651, 144651,
};
static av_always_inline int dv_init_enc_block(EncBlockInfo *bi, uint8_t *data,