Revision 6159bd0d

View differences:

libavcodec/ac3enc.c
310 310

  
311 311
    nb_coefs = FFMIN(s->nb_coefs[0], s->nb_coefs[1]);
312 312

  
313
    s->blocks[0].new_rematrixing_strategy = 1;
314 313
    for (blk = 0; blk < AC3_MAX_BLOCKS; blk++) {
315 314
        block = &s->blocks[blk];
315
        block->new_rematrixing_strategy = !blk;
316 316
        for (bnd = 0; bnd < 4; bnd++) {
317 317
            /* calculate calculate sum of squared coeffs for one band in one block */
318 318
            int start = ff_ac3_rematrix_band_tab[bnd];
......
337 337

  
338 338
            /* determine if new rematrixing flags will be sent */
339 339
            if (blk &&
340
                !block->new_rematrixing_strategy &&
341 340
                block->rematrixing_flags[bnd] != block0->rematrixing_flags[bnd]) {
342 341
                block->new_rematrixing_strategy = 1;
343 342
            }
tests/ref/acodec/ac3_fixed
1
f8eddf3c4e119bcb2aa89a76d7461259 *./tests/data/acodec/ac3.rm
1
07bd593823ebd721b3a32ef298bdfc20 *./tests/data/acodec/ac3.rm
2 2
98751 ./tests/data/acodec/ac3.rm
tests/ref/seek/ac3_rm
1 1
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
2 2
ret: 0         st:-1 flags:0  ts:-1.000000
3 3
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
4
ret:-1         st:-1 flags:1  ts: 1.894167
5
ret:-1         st: 0 flags:0  ts: 0.788000
4
ret: 0         st:-1 flags:1  ts: 1.894167
5
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
6
ret: 0         st: 0 flags:0  ts: 0.788000
7
ret: 0         st: 0 flags:1 dts:4160806.587000 pts:4160806.587000 pos:   3883 size:   116
6 8
ret: 0         st: 0 flags:1  ts:-0.317000
7 9
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
8
ret:-1         st:-1 flags:0  ts: 2.576668
10
ret: 0         st:-1 flags:0  ts: 2.576668
11
ret: 0         st: 0 flags:1 dts:4160806.587000 pts:4160806.587000 pos:   3883 size:   116
9 12
ret:-1         st:-1 flags:1  ts: 1.470835
10
ret:-1         st: 0 flags:0  ts: 0.365000
13
ret: 0         st: 0 flags:0  ts: 0.365000
14
ret: 0         st: 0 flags:1 dts:4160806.587000 pts:4160806.587000 pos:   3883 size:   116
11 15
ret: 0         st: 0 flags:1  ts:-0.741000
12 16
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
13 17
ret:-1         st:-1 flags:0  ts: 2.153336
......
16 20
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
17 21
ret:-1         st: 0 flags:1  ts: 2.836000
18 22
ret:-1         st:-1 flags:0  ts: 1.730004
19
ret:-1         st:-1 flags:1  ts: 0.624171
23
ret: 0         st:-1 flags:1  ts: 0.624171
24
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
20 25
ret: 0         st: 0 flags:0  ts:-0.482000
21 26
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
22
ret:-1         st: 0 flags:1  ts: 2.413000
27
ret: 0         st: 0 flags:1  ts: 2.413000
28
ret: 0         st: 0 flags:1 dts: 2.229000 pts: 2.229000 pos:  36705 size:   556
23 29
ret:-1         st:-1 flags:0  ts: 1.306672
24
ret:-1         st:-1 flags:1  ts: 0.200839
30
ret: 0         st:-1 flags:1  ts: 0.200839
31
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
25 32
ret: 0         st: 0 flags:0  ts:-0.905000
26 33
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
27 34
ret:-1         st: 0 flags:1  ts: 1.989000
28
ret:-1         st:-1 flags:0  ts: 0.883340
35
ret: 0         st:-1 flags:0  ts: 0.883340
36
ret: 0         st: 0 flags:1 dts:4160806.587000 pts:4160806.587000 pos:   3883 size:   116
29 37
ret: 0         st:-1 flags:1  ts:-0.222493
30 38
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556
31
ret:-1         st: 0 flags:0  ts: 2.672000
39
ret: 0         st: 0 flags:0  ts: 2.672000
40
ret: 0         st: 0 flags:1 dts:6354.691000 pts:6354.691000 pos:  10783 size:   304
32 41
ret:-1         st: 0 flags:1  ts: 1.566000
33
ret:-1         st:-1 flags:0  ts: 0.460008
42
ret: 0         st:-1 flags:0  ts: 0.460008
43
ret: 0         st: 0 flags:1 dts:4160806.587000 pts:4160806.587000 pos:   3883 size:   116
34 44
ret: 0         st:-1 flags:1  ts:-0.645825
35 45
ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    271 size:   556

Also available in: Unified diff