Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
aom-rav1e
Commits
a5e542e7
Commit
a5e542e7
authored
Nov 21, 2012
by
Ronald S. Bultje
Browse files
Fix enc/dec mismatch with b_context_pred experiment enabled.
Change-Id: I1272ae3f0fdfb7ed8eb364ef0c6dd1818d3179d7
parent
e25bd474
Changes
3
Hide whitespace changes
Inline
Side-by-side
vp9/decoder/decodframe.c
View file @
a5e542e7
...
...
@@ -395,7 +395,7 @@ static void decode_macroblock(VP9D_COMP *pbi, MACROBLOCKD *xd,
eobtotal
=
vp9_decode_mb_tokens_16x16
(
pbi
,
xd
,
bc
);
}
else
if
(
tx_size
==
TX_8X8
)
{
eobtotal
=
vp9_decode_mb_tokens_8x8
(
pbi
,
xd
,
bc
);
}
else
{
}
else
if
(
mode
!=
B_PRED
)
{
eobtotal
=
vp9_decode_mb_tokens_4x4
(
pbi
,
xd
,
bc
);
}
}
...
...
@@ -491,6 +491,8 @@ static void decode_macroblock(VP9D_COMP *pbi, MACROBLOCKD *xd,
xd
->
mode_info_context
->
bmi
[
i
].
as_mode
.
context
=
b
->
bmi
.
as_mode
.
context
=
vp9_find_bpred_context
(
b
);
#endif
if
(
!
xd
->
mode_info_context
->
mbmi
.
mb_skip_coeff
)
eobtotal
+=
vp9_decode_coefs_4x4
(
pbi
,
xd
,
bc
,
PLANE_TYPE_Y_WITH_DC
,
i
);
#if CONFIG_COMP_INTRA_PRED
b_mode2
=
xd
->
mode_info_context
->
bmi
[
i
].
as_mode
.
second
;
...
...
@@ -513,6 +515,8 @@ static void decode_macroblock(VP9D_COMP *pbi, MACROBLOCKD *xd,
*
(
b
->
base_dst
)
+
b
->
dst
,
16
,
b
->
dst_stride
);
}
}
if
(
!
xd
->
mode_info_context
->
mbmi
.
mb_skip_coeff
)
vp9_decode_mb_tokens_4x4_uv
(
pbi
,
xd
,
bc
);
}
else
if
(
mode
==
SPLITMV
)
{
if
(
tx_size
==
TX_8X8
)
{
vp9_dequant_idct_add_y_block_8x8
(
xd
->
qcoeff
,
xd
->
block
[
0
].
dequant
,
...
...
vp9/decoder/detokenize.c
View file @
a5e542e7
...
...
@@ -389,9 +389,9 @@ int vp9_decode_mb_tokens_8x8(VP9D_COMP* const pbi,
return
eobtotal
;
}
static
int
decode_coefs_4x4
(
VP9D_COMP
*
dx
,
MACROBLOCKD
*
xd
,
BOOL_DECODER
*
const
bc
,
PLANE_TYPE
type
,
int
i
)
{
int
vp9_
decode_coefs_4x4
(
VP9D_COMP
*
dx
,
MACROBLOCKD
*
xd
,
BOOL_DECODER
*
const
bc
,
PLANE_TYPE
type
,
int
i
)
{
ENTROPY_CONTEXT
*
const
A
=
(
ENTROPY_CONTEXT
*
)
xd
->
above_context
;
ENTROPY_CONTEXT
*
const
L
=
(
ENTROPY_CONTEXT
*
)
xd
->
left_context
;
ENTROPY_CONTEXT
*
const
a
=
A
+
vp9_block2above
[
i
];
...
...
@@ -424,6 +424,17 @@ static int decode_coefs_4x4(VP9D_COMP *dx, MACROBLOCKD *xd,
return
c
;
}
int
vp9_decode_mb_tokens_4x4_uv
(
VP9D_COMP
*
const
dx
,
MACROBLOCKD
*
const
xd
,
BOOL_DECODER
*
const
bc
)
{
int
eobtotal
=
0
,
i
;
for
(
i
=
16
;
i
<
24
;
i
++
)
eobtotal
+=
vp9_decode_coefs_4x4
(
dx
,
xd
,
bc
,
PLANE_TYPE_UV
,
i
);
return
eobtotal
;
}
int
vp9_decode_mb_tokens_4x4
(
VP9D_COMP
*
const
dx
,
MACROBLOCKD
*
const
xd
,
BOOL_DECODER
*
const
bc
)
{
...
...
@@ -433,17 +444,15 @@ int vp9_decode_mb_tokens_4x4(VP9D_COMP* const dx,
if
(
xd
->
mode_info_context
->
mbmi
.
mode
!=
B_PRED
&&
xd
->
mode_info_context
->
mbmi
.
mode
!=
I8X8_PRED
&&
xd
->
mode_info_context
->
mbmi
.
mode
!=
SPLITMV
)
{
eobtotal
+=
decode_coefs_4x4
(
dx
,
xd
,
bc
,
PLANE_TYPE_Y2
,
24
)
-
16
;
eobtotal
+=
vp9_
decode_coefs_4x4
(
dx
,
xd
,
bc
,
PLANE_TYPE_Y2
,
24
)
-
16
;
type
=
PLANE_TYPE_Y_NO_DC
;
}
else
{
type
=
PLANE_TYPE_Y_WITH_DC
;
}
for
(
i
=
0
;
i
<
16
;
++
i
)
{
eobtotal
+=
decode_coefs_4x4
(
dx
,
xd
,
bc
,
type
,
i
);
eobtotal
+=
vp9_
decode_coefs_4x4
(
dx
,
xd
,
bc
,
type
,
i
);
}
do
{
eobtotal
+=
decode_coefs_4x4
(
dx
,
xd
,
bc
,
PLANE_TYPE_UV
,
i
);
}
while
(
++
i
<
24
);
return
eobtotal
;
return
eobtotal
+
vp9_decode_mb_tokens_4x4_uv
(
dx
,
xd
,
bc
);
}
vp9/decoder/detokenize.h
View file @
a5e542e7
...
...
@@ -16,9 +16,16 @@
void
vp9_reset_mb_tokens_context
(
MACROBLOCKD
*
const
);
int
vp9_decode_coefs_4x4
(
VP9D_COMP
*
dx
,
MACROBLOCKD
*
xd
,
BOOL_DECODER
*
const
bc
,
PLANE_TYPE
type
,
int
i
);
int
vp9_decode_mb_tokens_4x4
(
VP9D_COMP
*
const
,
MACROBLOCKD
*
const
,
BOOL_DECODER
*
const
);
int
vp9_decode_mb_tokens_4x4_uv
(
VP9D_COMP
*
const
dx
,
MACROBLOCKD
*
const
xd
,
BOOL_DECODER
*
const
bc
);
int
vp9_decode_mb_tokens_8x8
(
VP9D_COMP
*
const
,
MACROBLOCKD
*
const
,
BOOL_DECODER
*
const
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment