Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Guillaume Martres
aom-rav1e
Commits
a7333b0a
Commit
a7333b0a
authored
Oct 10, 2012
by
Deb Mukherjee
Browse files
Merge of the TX_16X16 experiment
Change-Id: I22aa803ffff330622cdb77277e7b196a9766f882
parent
239b6a8f
Changes
39
Hide whitespace changes
Inline
Side-by-side
configure
View file @
a7333b0a
...
...
@@ -224,7 +224,6 @@ EXPERIMENT_LIST="
hybridtransform
hybridtransform8x8
switchable_interp
tx16x16
newbestrefmv
new_mvref
hybridtransform16x16
...
...
test/test.mk
View file @
a7333b0a
LIBVPX_TEST_SRCS-yes
+=
test.mk
LIBVPX_TEST_SRCS-yes
+=
acm_random.h
LIBVPX_TEST_SRCS-yes
+=
boolcoder_test.cc
LIBVPX_TEST_SRCS-
$(CONFIG_TX16X16)
+=
dct16x16_test.cc
LIBVPX_TEST_SRCS-
yes
+=
dct16x16_test.cc
LIBVPX_TEST_SRCS-yes
+=
fdct4x4_test.cc
LIBVPX_TEST_SRCS-yes
+=
fdct8x8_test.cc
LIBVPX_TEST_SRCS-yes
+=
idct8x8_test.cc
...
...
vp8/common/blockd.h
View file @
a7333b0a
...
...
@@ -129,9 +129,7 @@ typedef enum {
typedef
enum
{
TX_4X4
,
// 4x4 dct transform
TX_8X8
,
// 8x8 dct transform
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
TX_16X16
,
// 16x16 dct transform
#endif
TX_SIZE_MAX
// Number of different transforms available
}
TX_SIZE
;
...
...
vp8/common/coefupdateprobs.h
View file @
a7333b0a
...
...
@@ -13,7 +13,4 @@
Generated file included by entropy.c */
#define COEF_UPDATE_PROB 252
#define COEF_UPDATE_PROB_8X8 252
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
#define COEF_UPDATE_PROB_16X16 252
#endif
vp8/common/default_coef_probs.h
View file @
a7333b0a
...
...
@@ -966,7 +966,6 @@ default_hybrid_coef_probs_8x8[BLOCK_TYPES_8X8]
};
#endif
#if CONFIG_TX16X16
static
const
vp8_prob
default_coef_probs_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
...
...
@@ -1382,4 +1381,3 @@ static const vp8_prob
}
};
#endif
#endif
vp8/common/entropy.c
View file @
a7333b0a
...
...
@@ -97,7 +97,6 @@ DECLARE_ALIGNED(64, const int, vp8_default_zig_zag1d_8x8[64]) = {
58
,
59
,
52
,
45
,
38
,
31
,
39
,
46
,
53
,
60
,
61
,
54
,
47
,
55
,
62
,
63
,
};
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
// Table can be optimized.
DECLARE_ALIGNED
(
16
,
const
int
,
vp8_coef_bands_16x16
[
256
])
=
{
0
,
1
,
2
,
3
,
5
,
4
,
4
,
5
,
5
,
3
,
6
,
3
,
5
,
4
,
6
,
6
,
...
...
@@ -135,7 +134,6 @@ DECLARE_ALIGNED(16, const int, vp8_default_zig_zag1d_16x16[256]) = {
203
,
218
,
233
,
248
,
249
,
234
,
219
,
204
,
189
,
174
,
159
,
175
,
190
,
205
,
220
,
235
,
250
,
251
,
236
,
221
,
206
,
191
,
207
,
222
,
237
,
252
,
253
,
238
,
223
,
239
,
254
,
255
,
};
#endif
/* Array indices are identical to previously-existing CONTEXT_NODE indices */
...
...
@@ -222,7 +220,6 @@ void vp8_default_coef_probs(VP8_COMMON *pc) {
sizeof
(
pc
->
fc
.
hybrid_coef_probs_8x8
));
#endif
#if CONFIG_TX16X16
vpx_memcpy
(
pc
->
fc
.
coef_probs_16x16
,
default_coef_probs_16x16
,
sizeof
(
pc
->
fc
.
coef_probs_16x16
));
#if CONFIG_HYBRIDTRANSFORM16X16
...
...
@@ -230,7 +227,6 @@ void vp8_default_coef_probs(VP8_COMMON *pc) {
default_hybrid_coef_probs_16x16
,
sizeof
(
pc
->
fc
.
hybrid_coef_probs_16x16
));
#endif
#endif
}
void
vp8_coef_tree_initialize
()
{
...
...
@@ -419,7 +415,6 @@ void vp8_adapt_coef_probs(VP8_COMMON *cm) {
}
#endif
#if CONFIG_TX16X16
for
(
i
=
0
;
i
<
BLOCK_TYPES_16X16
;
++
i
)
for
(
j
=
0
;
j
<
COEF_BANDS
;
++
j
)
for
(
k
=
0
;
k
<
PREV_COEF_CONTEXTS
;
++
k
)
{
...
...
@@ -464,5 +459,4 @@ void vp8_adapt_coef_probs(VP8_COMMON *cm) {
}
}
#endif
#endif
}
vp8/common/entropy.h
View file @
a7333b0a
...
...
@@ -74,9 +74,7 @@ extern vp8_extra_bit_struct vp8_extra_bits[12]; /* indexed by token value */
#define COEF_BANDS 8
extern
DECLARE_ALIGNED
(
16
,
const
int
,
vp8_coef_bands
[
16
]);
extern
DECLARE_ALIGNED
(
64
,
const
int
,
vp8_coef_bands_8x8
[
64
]);
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
extern
DECLARE_ALIGNED
(
16
,
const
int
,
vp8_coef_bands_16x16
[
256
]);
#endif
/* Inside dimension is 3-valued measure of nearby complexity, that is,
the extent to which nearby coefficients are nonzero. For the first
...
...
@@ -115,9 +113,7 @@ extern short vp8_default_zig_zag_mask[16];
extern
DECLARE_ALIGNED
(
64
,
const
int
,
vp8_default_zig_zag1d_8x8
[
64
]);
void
vp8_coef_tree_initialize
(
void
);
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
extern
DECLARE_ALIGNED
(
16
,
const
int
,
vp8_default_zig_zag1d_16x16
[
256
]);
#endif
void
vp8_adapt_coef_probs
(
struct
VP8Common
*
);
#endif
vp8/common/generic/systemdependent.c
View file @
a7333b0a
...
...
@@ -33,9 +33,8 @@ void vp8_machine_specific_config(VP8_COMMON *ctx) {
rtcd
->
idct
.
idct8
=
vp8_short_idct8x8_c
;
rtcd
->
idct
.
idct1_scalar_add_8x8
=
vp8_dc_only_idct_add_8x8_c
;
rtcd
->
idct
.
ihaar2
=
vp8_short_ihaar2x2_c
;
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
rtcd
->
idct
.
idct16x16
=
vp8_short_idct16x16_c
;
#endif
rtcd
->
recon
.
copy16x16
=
vp8_copy_mem16x16_c
;
rtcd
->
recon
.
copy8x8
=
vp8_copy_mem8x8_c
;
rtcd
->
recon
.
avg16x16
=
vp8_avg_mem16x16_c
;
rtcd
->
recon
.
avg8x8
=
vp8_avg_mem8x8_c
;
...
...
vp8/common/idct.h
View file @
a7333b0a
...
...
@@ -43,12 +43,10 @@
#define Y2_WHT_UPSCALE_FACTOR 2
#endif
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
#ifndef vp8_idct_idct16x16
#define vp8_idct_idct16x16 vp8_short_idct16x16_c
#endif
extern
prototype_idct
(
vp8_idct_idct16x16
);
#endif
#ifndef vp8_idct_idct8
#define vp8_idct_idct8 vp8_short_idct8x8_c
...
...
@@ -136,9 +134,7 @@ typedef struct {
vp8_idct_fn_t
ihaar2
;
vp8_idct_fn_t
ihaar2_1
;
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
vp8_idct_fn_t
idct16x16
;
#endif
}
vp8_idct_rtcd_vtable_t
;
#if CONFIG_RUNTIME_CPU_DETECT
...
...
vp8/common/idctllm.c
View file @
a7333b0a
...
...
@@ -779,7 +779,6 @@ void vp8_short_ihaar2x2_c(short *input, short *output, int pitch) {
}
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
#if 0
// Keep a really bad float version as reference for now.
void vp8_short_idct16x16_c(short *input, short *output, int pitch) {
...
...
@@ -1070,4 +1069,3 @@ void vp8_short_idct16x16_c(short *input, short *output, int pitch) {
}
vp8_clear_system_state
();
// Make it simd safe : __asm emms;
}
#endif
vp8/common/invtrans.c
View file @
a7333b0a
...
...
@@ -171,7 +171,6 @@ void vp8_inverse_transform_mb_8x8(const vp8_idct_rtcd_vtable_t *rtcd,
}
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
void
vp8_inverse_transform_b_16x16
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
short
*
input_dqcoeff
,
short
*
output_coeff
,
int
pitch
)
{
...
...
@@ -210,4 +209,3 @@ void vp8_inverse_transform_mb_16x16(const vp8_idct_rtcd_vtable_t *rtcd,
vp8_inverse_transform_b_8x8
(
rtcd
,
&
blockd
[
i
].
dqcoeff
[
0
],
&
blockd
[
i
].
diff
[
0
],
16
);
}
#endif
vp8/common/invtrans.h
View file @
a7333b0a
...
...
@@ -30,7 +30,6 @@ extern void vp8_inverse_transform_mb_8x8(const vp8_idct_rtcd_vtable_t *rtcd, MAC
extern
void
vp8_inverse_transform_mby_8x8
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
MACROBLOCKD
*
xd
);
extern
void
vp8_inverse_transform_mbuv_8x8
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
MACROBLOCKD
*
xd
);
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
extern
void
vp8_inverse_transform_b_16x16
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
short
*
input_dqcoeff
,
short
*
output_coeff
,
int
pitch
);
...
...
@@ -38,4 +37,3 @@ extern void vp8_inverse_transform_mb_16x16(const vp8_idct_rtcd_vtable_t *rtcd, M
extern
void
vp8_inverse_transform_mby_16x16
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
MACROBLOCKD
*
xd
);
extern
void
vp8_inverse_transform_mbuv_16x16
(
const
vp8_idct_rtcd_vtable_t
*
rtcd
,
MACROBLOCKD
*
xd
);
#endif
#endif
vp8/common/loopfilter.c
View file @
a7333b0a
...
...
@@ -335,11 +335,7 @@ void vp8_loop_filter_frame
vp8_loop_filter_mbv_c
(
y_ptr
,
u_ptr
,
v_ptr
,
post
->
y_stride
,
post
->
uv_stride
,
&
lfi
);
if
(
!
skip_lf
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
&&
tx_type
!=
TX_16X16
#endif
)
{
if
(
!
skip_lf
&&
tx_type
!=
TX_16X16
)
{
if
(
tx_type
==
TX_8X8
)
vp8_loop_filter_bv8x8_c
(
y_ptr
,
u_ptr
,
v_ptr
,
post
->
y_stride
,
post
->
uv_stride
,
&
lfi
);
...
...
@@ -360,11 +356,7 @@ void vp8_loop_filter_frame
vp8_loop_filter_mbh_c
(
y_ptr
,
u_ptr
,
v_ptr
,
post
->
y_stride
,
post
->
uv_stride
,
&
lfi
);
if
(
!
skip_lf
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
&&
tx_type
!=
TX_16X16
#endif
)
{
if
(
!
skip_lf
&&
tx_type
!=
TX_16X16
)
{
if
(
tx_type
==
TX_8X8
)
vp8_loop_filter_bh8x8_c
(
y_ptr
,
u_ptr
,
v_ptr
,
post
->
y_stride
,
post
->
uv_stride
,
&
lfi
);
...
...
@@ -478,11 +470,7 @@ void vp8_loop_filter_frame_yonly
vp8_loop_filter_mbv_c
(
y_ptr
,
0
,
0
,
post
->
y_stride
,
0
,
&
lfi
);
if
(
!
skip_lf
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
&&
tx_type
!=
TX_16X16
#endif
)
{
if
(
!
skip_lf
&&
tx_type
!=
TX_16X16
)
{
if
(
tx_type
==
TX_8X8
)
vp8_loop_filter_bv8x8_c
(
y_ptr
,
0
,
0
,
post
->
y_stride
,
0
,
&
lfi
);
...
...
@@ -496,11 +484,7 @@ void vp8_loop_filter_frame_yonly
vp8_loop_filter_mbh_c
(
y_ptr
,
0
,
0
,
post
->
y_stride
,
0
,
&
lfi
);
if
(
!
skip_lf
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
&&
tx_type
!=
TX_16X16
#endif
)
{
if
(
!
skip_lf
&&
tx_type
!=
TX_16X16
)
{
if
(
tx_type
==
TX_8X8
)
vp8_loop_filter_bh8x8_c
(
y_ptr
,
0
,
0
,
post
->
y_stride
,
0
,
&
lfi
);
...
...
vp8/common/onyxc_int.h
View file @
a7333b0a
...
...
@@ -59,12 +59,10 @@ typedef struct frame_contexts {
#if CONFIG_HYBRIDTRANSFORM8X8
vp8_prob
hybrid_coef_probs_8x8
[
BLOCK_TYPES_8X8
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#endif
#if CONFIG_TX16X16
vp8_prob
coef_probs_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#if CONFIG_HYBRIDTRANSFORM16X16
vp8_prob
hybrid_coef_probs_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#endif
#endif
#if CONFIG_NEWMVENTROPY
nmv_context
nmvc
;
...
...
@@ -102,13 +100,11 @@ typedef struct frame_contexts {
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#endif
#if CONFIG_TX16X16
vp8_prob
pre_coef_probs_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#if CONFIG_HYBRIDTRANSFORM16X16
vp8_prob
pre_hybrid_coef_probs_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
ENTROPY_NODES
];
#endif
#endif
unsigned
int
coef_counts
[
BLOCK_TYPES
]
[
COEF_BANDS
]
...
...
@@ -125,14 +121,12 @@ typedef struct frame_contexts {
[
PREV_COEF_CONTEXTS
]
[
MAX_ENTROPY_TOKENS
];
#endif
#if CONFIG_TX16X16
unsigned
int
coef_counts_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
MAX_ENTROPY_TOKENS
];
#if CONFIG_HYBRIDTRANSFORM16X16
unsigned
int
hybrid_coef_counts_16x16
[
BLOCK_TYPES_16X16
]
[
COEF_BANDS
]
[
PREV_COEF_CONTEXTS
]
[
MAX_ENTROPY_TOKENS
];
#endif
#endif
#if CONFIG_NEWMVENTROPY
nmv_context_counts
NMVcount
;
...
...
@@ -167,13 +161,11 @@ typedef enum {
typedef
enum
{
ONLY_4X4
=
0
,
ALLOW_8X8
=
1
,
#if CONFIG_TX16X16
ALLOW_16X16
=
2
,
#endif
#if CONFIG_TX_SELECT
TX_MODE_SELECT
=
2
+
CONFIG_TX16X16
,
TX_MODE_SELECT
=
3
,
#endif
NB_TXFM_MODES
=
2
+
CONFIG_TX16X16
+
CONFIG_TX_SELECT
,
NB_TXFM_MODES
=
3
+
CONFIG_TX_SELECT
,
}
TXFM_MODE
;
typedef
struct
VP8_COMMON_RTCD
{
...
...
vp8/decoder/decodemv.c
View file @
a7333b0a
...
...
@@ -175,18 +175,13 @@ static void vp8_kfread_modes(VP8D_COMP *pbi,
m
->
mbmi
.
mode
<=
TM_PRED
)
{
// FIXME(rbultje) code ternary symbol once all experiments are merged
m
->
mbmi
.
txfm_size
=
vp8_read
(
bc
,
cm
->
prob_tx
[
0
]);
#if CONFIG_TX16X16
if
(
m
->
mbmi
.
txfm_size
!=
TX_4X4
)
m
->
mbmi
.
txfm_size
+=
vp8_read
(
bc
,
cm
->
prob_tx
[
1
]);
#endif
}
else
#endif
#if CONFIG_TX16X16
if
(
cm
->
txfm_mode
>=
ALLOW_16X16
&&
m
->
mbmi
.
mode
<=
TM_PRED
)
{
m
->
mbmi
.
txfm_size
=
TX_16X16
;
}
else
#endif
if
(
cm
->
txfm_mode
>=
ALLOW_8X8
&&
m
->
mbmi
.
mode
!=
B_PRED
)
{
}
else
if
(
cm
->
txfm_mode
>=
ALLOW_8X8
&&
m
->
mbmi
.
mode
!=
B_PRED
)
{
m
->
mbmi
.
txfm_size
=
TX_8X8
;
}
else
{
m
->
mbmi
.
txfm_size
=
TX_4X4
;
...
...
@@ -1290,20 +1285,15 @@ static void read_mb_modes_mv(VP8D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
(
mbmi
->
ref_frame
!=
INTRA_FRAME
&&
mbmi
->
mode
!=
SPLITMV
)))
{
// FIXME(rbultje) code ternary symbol once all experiments are merged
mbmi
->
txfm_size
=
vp8_read
(
bc
,
cm
->
prob_tx
[
0
]);
#if CONFIG_TX16X16
if
(
mbmi
->
txfm_size
!=
TX_4X4
)
mbmi
->
txfm_size
+=
vp8_read
(
bc
,
cm
->
prob_tx
[
1
]);
#endif
}
else
#endif
#if CONFIG_TX16X16
if
(
cm
->
txfm_mode
>=
ALLOW_16X16
&&
((
mbmi
->
ref_frame
==
INTRA_FRAME
&&
mbmi
->
mode
<=
TM_PRED
)
||
(
mbmi
->
ref_frame
!=
INTRA_FRAME
&&
mbmi
->
mode
!=
SPLITMV
)))
{
mbmi
->
txfm_size
=
TX_16X16
;
}
else
#endif
if
(
cm
->
txfm_mode
>=
ALLOW_8X8
&&
}
else
if
(
cm
->
txfm_mode
>=
ALLOW_8X8
&&
((
mbmi
->
ref_frame
==
INTRA_FRAME
&&
mbmi
->
mode
!=
B_PRED
)
||
(
mbmi
->
ref_frame
!=
INTRA_FRAME
&&
mbmi
->
mode
!=
SPLITMV
)))
{
mbmi
->
txfm_size
=
TX_8X8
;
...
...
vp8/decoder/decodframe.c
View file @
a7333b0a
...
...
@@ -290,12 +290,9 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
xd
->
block
[
i
].
eob
=
0
;
xd
->
eobs
[
i
]
=
0
;
}
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
if
(
tx_type
==
TX_16X16
)
eobtotal
=
vp8_decode_mb_tokens_16x16
(
pbi
,
xd
);
else
#endif
if
(
tx_type
==
TX_8X8
)
else
if
(
tx_type
==
TX_8X8
)
eobtotal
=
vp8_decode_mb_tokens_8x8
(
pbi
,
xd
);
else
eobtotal
=
vp8_decode_mb_tokens
(
pbi
,
xd
);
...
...
@@ -457,7 +454,6 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
}
else
{
BLOCKD
*
b
=
&
xd
->
block
[
24
];
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
if
(
tx_type
==
TX_16X16
)
{
#if CONFIG_HYBRIDTRANSFORM16X16
if
(
mode
<
I8X8_PRED
&&
active_ht16
)
{
...
...
@@ -480,9 +476,7 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
16
,
xd
->
dst
.
y_stride
);
#endif
}
else
#endif
if
(
tx_type
==
TX_8X8
)
{
else
if
(
tx_type
==
TX_8X8
)
{
#if CONFIG_SUPERBLOCKS
void
*
orig
=
xd
->
mode_info_context
;
int
n
,
num
=
xd
->
mode_info_context
->
mbmi
.
encoded_as_sb
?
4
:
1
;
...
...
@@ -569,9 +563,7 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
#endif
if
((
tx_type
==
TX_8X8
&&
xd
->
mode_info_context
->
mbmi
.
mode
!=
I8X8_PRED
)
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
||
tx_type
==
TX_16X16
#endif
)
DEQUANT_INVOKE
(
&
pbi
->
dequant
,
idct_add_uv_block_8x8
)
//
(
xd
->
qcoeff
+
16
*
16
,
xd
->
block
[
16
].
dequant
,
...
...
@@ -1012,7 +1004,6 @@ static void read_coef_probs(VP8D_COMP *pbi) {
}
#endif
#if CONFIG_TX16X16
// 16x16
if
(
pbi
->
common
.
txfm_mode
>
ALLOW_8X8
&&
vp8_read_bit
(
bc
))
{
// read coef probability tree
...
...
@@ -1052,7 +1043,6 @@ static void read_coef_probs(VP8D_COMP *pbi) {
}
}
#endif
#endif
}
int
vp8_decode_frame
(
VP8D_COMP
*
pbi
)
{
...
...
@@ -1282,25 +1272,15 @@ int vp8_decode_frame(VP8D_COMP *pbi) {
/* Read the loop filter level and type */
#if CONFIG_TX_SELECT
#if CONFIG_TX16X16
pc
->
txfm_mode
=
vp8_read_literal
(
bc
,
2
);
#else
pc
->
txfm_mode
=
vp8_read_bit
(
bc
);
if
(
pc
->
txfm_mode
)
pc
->
txfm_mode
+=
vp8_read_bit
(
bc
);
#endif
if
(
pc
->
txfm_mode
==
TX_MODE_SELECT
)
{
pc
->
prob_tx
[
0
]
=
vp8_read_literal
(
bc
,
8
);
#if CONFIG_TX16X16
pc
->
prob_tx
[
1
]
=
vp8_read_literal
(
bc
,
8
);
#endif
}
#else
pc
->
txfm_mode
=
(
TXFM_MODE
)
vp8_read_bit
(
bc
);
#if CONFIG_TX16X16
if
(
pc
->
txfm_mode
==
ALLOW_8X8
)
pc
->
txfm_mode
=
ALLOW_16X16
;
#endif
#endif
pc
->
filter_type
=
(
LOOPFILTERTYPE
)
vp8_read_bit
(
bc
);
...
...
@@ -1445,13 +1425,11 @@ int vp8_decode_frame(VP8D_COMP *pbi) {
vp8_copy
(
pbi
->
common
.
fc
.
pre_hybrid_coef_probs_8x8
,
pbi
->
common
.
fc
.
hybrid_coef_probs_8x8
);
#endif
#if CONFIG_TX16X16
vp8_copy
(
pbi
->
common
.
fc
.
pre_coef_probs_16x16
,
pbi
->
common
.
fc
.
coef_probs_16x16
);
#if CONFIG_HYBRIDTRANSFORM16X16
vp8_copy
(
pbi
->
common
.
fc
.
pre_hybrid_coef_probs_16x16
,
pbi
->
common
.
fc
.
hybrid_coef_probs_16x16
);
#endif
#endif
vp8_copy
(
pbi
->
common
.
fc
.
pre_ymode_prob
,
pbi
->
common
.
fc
.
ymode_prob
);
vp8_copy
(
pbi
->
common
.
fc
.
pre_uv_mode_prob
,
pbi
->
common
.
fc
.
uv_mode_prob
);
...
...
@@ -1473,11 +1451,9 @@ int vp8_decode_frame(VP8D_COMP *pbi) {
#if CONFIG_HYBRIDTRANSFORM8X8
vp8_zero
(
pbi
->
common
.
fc
.
hybrid_coef_counts_8x8
);
#endif
#if CONFIG_TX16X16
vp8_zero
(
pbi
->
common
.
fc
.
coef_counts_16x16
);
#if CONFIG_HYBRIDTRANSFORM16X16
vp8_zero
(
pbi
->
common
.
fc
.
hybrid_coef_counts_16x16
);
#endif
#endif
vp8_zero
(
pbi
->
common
.
fc
.
ymode_counts
);
vp8_zero
(
pbi
->
common
.
fc
.
uv_mode_counts
);
...
...
vp8/decoder/dequantize.c
View file @
a7333b0a
...
...
@@ -509,7 +509,6 @@ void vp8_ht_dequant_idct_add_16x16_c(TX_TYPE tx_type, short *input, short *dq,
}
#endif
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
void
vp8_dequant_idct_add_16x16_c
(
short
*
input
,
short
*
dq
,
unsigned
char
*
pred
,
unsigned
char
*
dest
,
int
pitch
,
int
stride
)
{
short
output
[
256
];
...
...
@@ -544,4 +543,3 @@ void vp8_dequant_idct_add_16x16_c(short *input, short *dq, unsigned char *pred,
pred
+=
pitch
;
}
}
#endif
vp8/decoder/dequantize.h
View file @
a7333b0a
...
...
@@ -145,12 +145,10 @@ extern prototype_dequant_idct_add_y_block_8x8(vp8_dequant_idct_add_y_block_8x8);
#endif
extern
prototype_dequant_idct_add_uv_block_8x8
(
vp8_dequant_idct_add_uv_block_8x8
);
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
#ifndef vp8_dequant_idct_add_16x16
#define vp8_dequant_idct_add_16x16 vp8_dequant_idct_add_16x16_c
#endif
extern
prototype_dequant_idct_add
(
vp8_dequant_idct_add_16x16
);
#endif
typedef
prototype_dequant_block
((
*
vp8_dequant_block_fn_t
));
...
...
@@ -184,9 +182,7 @@ typedef struct {
vp8_dequant_dc_idct_add_y_block_fn_t_8x8
dc_idct_add_y_block_8x8
;
vp8_dequant_idct_add_y_block_fn_t_8x8
idct_add_y_block_8x8
;
vp8_dequant_idct_add_uv_block_fn_t_8x8
idct_add_uv_block_8x8
;
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
vp8_dequant_idct_add_fn_t
idct_add_16x16
;
#endif
}
vp8_dequant_rtcd_vtable_t
;
#if CONFIG_RUNTIME_CPU_DETECT
...
...
vp8/decoder/detokenize.c
View file @
a7333b0a
...
...
@@ -39,7 +39,6 @@ DECLARE_ALIGNED(16, const int, coef_bands_x_8x8[64]) = {
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
};
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
DECLARE_ALIGNED
(
16
,
const
int
,
coef_bands_x_16x16
[
256
])
=
{
0
*
OCB_X
,
1
*
OCB_X
,
2
*
OCB_X
,
3
*
OCB_X
,
5
*
OCB_X
,
4
*
OCB_X
,
4
*
OCB_X
,
5
*
OCB_X
,
5
*
OCB_X
,
3
*
OCB_X
,
6
*
OCB_X
,
3
*
OCB_X
,
5
*
OCB_X
,
4
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
5
*
OCB_X
,
5
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
6
*
OCB_X
,
...
...
@@ -58,7 +57,6 @@ DECLARE_ALIGNED(16, const int, coef_bands_x_16x16[256]) = {
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
,
7
*
OCB_X
};
#endif
#define EOB_CONTEXT_NODE 0
#define ZERO_CONTEXT_NODE 1
...
...
@@ -105,9 +103,7 @@ void vp8_reset_mb_tokens_context(MACROBLOCKD *xd) {
if
((
xd
->
mode_info_context
->
mbmi
.
mode
!=
B_PRED
&&
xd
->
mode_info_context
->
mbmi
.
mode
!=
I8X8_PRED
&&
xd
->
mode_info_context
->
mbmi
.
mode
!=
SPLITMV
)
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
||
xd
->
mode_info_context
->
mbmi
.
txfm_size
==
TX_16X16
#endif
)
{
vpx_memset
(
xd
->
above_context
,
0
,
sizeof
(
ENTROPY_CONTEXT_PLANES
));
vpx_memset
(
xd
->
left_context
,
0
,
sizeof
(
ENTROPY_CONTEXT_PLANES
));
...
...
@@ -237,7 +233,6 @@ void static count_tokens_8x8(INT16 *qcoeff_ptr, int block, int type,
}
}
#if CONFIG_TX16X16
void
static
count_tokens_16x16
(
INT16
*
qcoeff_ptr
,
int
block
,
int
type
,
#if CONFIG_HYBRIDTRANSFORM16X16
TX_TYPE
tx_type
,
...
...
@@ -269,8 +264,6 @@ void static count_tokens_16x16(INT16 *qcoeff_ptr, int block, int type,
fc
->
coef_counts_16x16
[
type
][
band
][
pt
][
DCT_EOB_TOKEN
]
++
;
}
}
#endif
static
int
vp8_get_signed
(
BOOL_DECODER
*
br
,
int
value_to_sign
)
{
const
int
split
=
(
br
->
range
+
1
)
>>
1
;
...
...
@@ -338,7 +331,6 @@ static int vp8_decode_coefs(VP8D_COMP *dx, const MACROBLOCKD *xd,
#endif
fc
->
coef_probs_8x8
[
type
][
0
][
0
];
break
;
#if CONFIG_TX16X16
case
TX_16X16
:
coef_probs
=
#if CONFIG_HYBRIDTRANSFORM16X16
...
...
@@ -346,7 +338,6 @@ static int vp8_decode_coefs(VP8D_COMP *dx, const MACROBLOCKD *xd,
#endif
fc
->
coef_probs_16x16
[
type
][
0
][
0
];
break
;
#endif
}
VP8_COMBINEENTROPYCONTEXTS
(
tmp
,
*
a
,
*
l
);
...
...
@@ -445,18 +436,15 @@ SKIP_START:
tx_type
,
#endif
a
,
l
,
c
,
seg_eob
,
fc
);
#if CONFIG_TX16X16
else
count_tokens_16x16
(
qcoeff_ptr
,
i
,
type
,
#if CONFIG_HYBRIDTRANSFORM16X16
tx_type
,
#endif
a
,
l
,
c
,
seg_eob
,
fc
);
#endif
return
c
;
}
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
int
vp8_decode_mb_tokens_16x16
(
VP8D_COMP
*
pbi
,
MACROBLOCKD
*
xd
)
{
ENTROPY_CONTEXT
*
const
A
=
(
ENTROPY_CONTEXT
*
)
xd
->
above_context
;
ENTROPY_CONTEXT
*
const
L
=
(
ENTROPY_CONTEXT
*
)
xd
->
left_context
;
...
...
@@ -532,8 +520,6 @@ int vp8_decode_mb_tokens_16x16(VP8D_COMP *pbi, MACROBLOCKD *xd) {
vpx_memset
(
&
L
[
8
],
0
,
sizeof
(
L
[
8
]));
return
eobtotal
;
}
#endif
int
vp8_decode_mb_tokens_8x8
(
VP8D_COMP
*
pbi
,
MACROBLOCKD
*
xd
)
{
ENTROPY_CONTEXT
*
const
A
=
(
ENTROPY_CONTEXT
*
)
xd
->
above_context
;
...
...
vp8/decoder/detokenize.h
View file @
a7333b0a
...
...
@@ -17,8 +17,6 @@
void
vp8_reset_mb_tokens_context
(
MACROBLOCKD
*
xd
);
int
vp8_decode_mb_tokens
(
VP8D_COMP
*
,
MACROBLOCKD
*
);
int
vp8_decode_mb_tokens_8x8
(
VP8D_COMP
*
,
MACROBLOCKD
*
);
#if CONFIG_TX16X16 || CONFIG_HYBRIDTRANSFORM16X16
int
vp8_decode_mb_tokens_16x16
(
VP8D_COMP
*
,
MACROBLOCKD
*
);
#endif
#endif
/* DETOKENIZE_H */
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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