24 #define PRED4x4(TYPE, DEPTH, OPT) \
25 void ff_pred4x4_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, const uint8_t *topright, int stride);
33 PRED4x4(vertical_left, 10, sse2)
35 PRED4x4(vertical_right, 10, sse2)
36 PRED4x4(vertical_right, 10, ssse3)
37 PRED4x4(vertical_right, 10, avx)
38 PRED4x4(horizontal_up, 10, mmxext)
39 PRED4x4(horizontal_down, 10, sse2)
40 PRED4x4(horizontal_down, 10, ssse3)
41 PRED4x4(horizontal_down, 10, avx)
43 #define PRED8x8(TYPE, DEPTH, OPT) \
44 void ff_pred8x8_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int stride);
48 PRED8x8(top_dc, 10, sse2)
49 PRED8x8(plane, 10, sse2)
50 PRED8x8(vertical, 10, sse2)
51 PRED8x8(horizontal, 10, sse2)
53 #define PRED8x8L(TYPE, DEPTH, OPT)\
54 void ff_pred8x8l_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int has_topleft, int has_topright, int stride);
58 PRED8x8L(128_dc, 10, mmxext)
59 PRED8x8L(128_dc, 10, sse2)
60 PRED8x8L(top_dc, 10, sse2)
61 PRED8x8L(top_dc, 10, avx)
62 PRED8x8L(vertical, 10, sse2)
63 PRED8x8L(vertical, 10, avx)
64 PRED8x8L(horizontal, 10, sse2)
65 PRED8x8L(horizontal, 10, ssse3)
66 PRED8x8L(horizontal, 10, avx)
67 PRED8x8L(down_left, 10, sse2)
68 PRED8x8L(down_left, 10, ssse3)
69 PRED8x8L(down_left, 10, avx)
70 PRED8x8L(down_right, 10, sse2)
71 PRED8x8L(down_right, 10, ssse3)
72 PRED8x8L(down_right, 10, avx)
73 PRED8x8L(vertical_right, 10, sse2)
74 PRED8x8L(vertical_right, 10, ssse3)
75 PRED8x8L(vertical_right, 10, avx)
76 PRED8x8L(horizontal_up, 10, sse2)
77 PRED8x8L(horizontal_up, 10, ssse3)
78 PRED8x8L(horizontal_up, 10, avx)
80 #define PRED16x16(TYPE, DEPTH, OPT)\
81 void ff_pred16x16_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int stride);
84 PRED16x16(dc, 10, sse2)
85 PRED16x16(top_dc, 10, mmxext)
86 PRED16x16(top_dc, 10, sse2)
87 PRED16x16(128_dc, 10, mmxext)
88 PRED16x16(128_dc, 10, sse2)
89 PRED16x16(left_dc, 10, mmxext)
90 PRED16x16(left_dc, 10, sse2)
91 PRED16x16(vertical, 10, mmxext)
92 PRED16x16(vertical, 10, sse2)
93 PRED16x16(horizontal, 10, mmxext)
94 PRED16x16(horizontal, 10, sse2)
96 void ff_pred16x16_vertical_mmx (uint8_t *src,
int stride);
97 void ff_pred16x16_vertical_sse (uint8_t *src,
int stride);
98 void ff_pred16x16_horizontal_mmx (uint8_t *src,
int stride);
99 void ff_pred16x16_horizontal_mmxext(uint8_t *src,
int stride);
100 void ff_pred16x16_horizontal_ssse3 (uint8_t *src,
int stride);
101 void ff_pred16x16_dc_mmxext (uint8_t *src,
int stride);
102 void ff_pred16x16_dc_sse2 (uint8_t *src,
int stride);
103 void ff_pred16x16_dc_ssse3 (uint8_t *src,
int stride);
104 void ff_pred16x16_plane_h264_mmx (uint8_t *src,
int stride);
105 void ff_pred16x16_plane_h264_mmx2 (uint8_t *src,
int stride);
106 void ff_pred16x16_plane_h264_sse2 (uint8_t *src,
int stride);
107 void ff_pred16x16_plane_h264_ssse3 (uint8_t *src,
int stride);
108 void ff_pred16x16_plane_rv40_mmx (uint8_t *src,
int stride);
109 void ff_pred16x16_plane_rv40_mmx2 (uint8_t *src,
int stride);
110 void ff_pred16x16_plane_rv40_sse2 (uint8_t *src,
int stride);
111 void ff_pred16x16_plane_rv40_ssse3 (uint8_t *src,
int stride);
112 void ff_pred16x16_plane_svq3_mmx (uint8_t *src,
int stride);
113 void ff_pred16x16_plane_svq3_mmx2 (uint8_t *src,
int stride);
114 void ff_pred16x16_plane_svq3_sse2 (uint8_t *src,
int stride);
115 void ff_pred16x16_plane_svq3_ssse3 (uint8_t *src,
int stride);
116 void ff_pred16x16_tm_vp8_mmx (uint8_t *src,
int stride);
117 void ff_pred16x16_tm_vp8_mmxext (uint8_t *src,
int stride);
118 void ff_pred16x16_tm_vp8_sse2 (uint8_t *src,
int stride);
119 void ff_pred8x8_top_dc_mmxext (uint8_t *src,
int stride);
120 void ff_pred8x8_dc_rv40_mmxext (uint8_t *src,
int stride);
121 void ff_pred8x8_dc_mmxext (uint8_t *src,
int stride);
122 void ff_pred8x8_vertical_mmx (uint8_t *src,
int stride);
123 void ff_pred8x8_horizontal_mmx (uint8_t *src,
int stride);
124 void ff_pred8x8_horizontal_mmxext (uint8_t *src,
int stride);
125 void ff_pred8x8_horizontal_ssse3 (uint8_t *src,
int stride);
126 void ff_pred8x8_plane_mmx (uint8_t *src,
int stride);
127 void ff_pred8x8_plane_mmx2 (uint8_t *src,
int stride);
128 void ff_pred8x8_plane_sse2 (uint8_t *src,
int stride);
129 void ff_pred8x8_plane_ssse3 (uint8_t *src,
int stride);
130 void ff_pred8x8_tm_vp8_mmx (uint8_t *src,
int stride);
131 void ff_pred8x8_tm_vp8_mmxext (uint8_t *src,
int stride);
132 void ff_pred8x8_tm_vp8_sse2 (uint8_t *src,
int stride);
133 void ff_pred8x8_tm_vp8_ssse3 (uint8_t *src,
int stride);
134 void ff_pred8x8l_top_dc_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
135 void ff_pred8x8l_top_dc_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
136 void ff_pred8x8l_dc_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
137 void ff_pred8x8l_dc_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
138 void ff_pred8x8l_horizontal_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
139 void ff_pred8x8l_horizontal_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
140 void ff_pred8x8l_vertical_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
141 void ff_pred8x8l_vertical_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
142 void ff_pred8x8l_down_left_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
143 void ff_pred8x8l_down_left_sse2 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
144 void ff_pred8x8l_down_left_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
145 void ff_pred8x8l_down_right_mmxext (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
146 void ff_pred8x8l_down_right_sse2 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
147 void ff_pred8x8l_down_right_ssse3 (uint8_t *src,
int has_topleft,
int has_topright,
int stride);
148 void ff_pred8x8l_vertical_right_mmxext(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
149 void ff_pred8x8l_vertical_right_sse2(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
150 void ff_pred8x8l_vertical_right_ssse3(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
151 void ff_pred8x8l_vertical_left_sse2(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
152 void ff_pred8x8l_vertical_left_ssse3(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
153 void ff_pred8x8l_horizontal_up_mmxext(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
154 void ff_pred8x8l_horizontal_up_ssse3(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
155 void ff_pred8x8l_horizontal_down_mmxext(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
156 void ff_pred8x8l_horizontal_down_sse2(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
157 void ff_pred8x8l_horizontal_down_ssse3(uint8_t *src,
int has_topleft,
int has_topright,
int stride);
158 void ff_pred4x4_dc_mmxext (uint8_t *src, const uint8_t *topright,
int stride);
159 void ff_pred4x4_down_left_mmxext (uint8_t *src, const uint8_t *topright,
int stride);
160 void ff_pred4x4_down_right_mmxext (uint8_t *src, const uint8_t *topright,
int stride);
161 void ff_pred4x4_vertical_left_mmxext(uint8_t *src, const uint8_t *topright,
int stride);
162 void ff_pred4x4_vertical_right_mmxext(uint8_t *src, const uint8_t *topright,
int stride);
163 void ff_pred4x4_horizontal_up_mmxext(uint8_t *src, const uint8_t *topright,
int stride);
164 void ff_pred4x4_horizontal_down_mmxext(uint8_t *src, const uint8_t *topright,
int stride);
165 void ff_pred4x4_tm_vp8_mmx (uint8_t *src, const uint8_t *topright,
int stride);
166 void ff_pred4x4_tm_vp8_mmxext (uint8_t *src, const uint8_t *topright,
int stride);
167 void ff_pred4x4_tm_vp8_ssse3 (uint8_t *src, const uint8_t *topright,
int stride);
168 void ff_pred4x4_vertical_vp8_mmxext(uint8_t *src, const uint8_t *topright,
int stride);
175 if (bit_depth == 8) {
177 h->pred16x16[
VERT_PRED8x8 ] = ff_pred16x16_vertical_mmx;
178 h->pred16x16[
HOR_PRED8x8 ] = ff_pred16x16_horizontal_mmx;
179 if (chroma_format_idc == 1) {
181 h->pred8x8 [
HOR_PRED8x8 ] = ff_pred8x8_horizontal_mmx;
188 if (chroma_format_idc == 1)
201 h->pred16x16[
HOR_PRED8x8 ] = ff_pred16x16_horizontal_mmxext;
202 h->pred16x16[
DC_PRED8x8 ] = ff_pred16x16_dc_mmxext;
203 if (chroma_format_idc == 1)
204 h->pred8x8[
HOR_PRED8x8 ] = ff_pred8x8_horizontal_mmxext;
205 h->pred8x8l [
TOP_DC_PRED ] = ff_pred8x8l_top_dc_mmxext;
206 h->pred8x8l [
DC_PRED ] = ff_pred8x8l_dc_mmxext;
207 h->pred8x8l [
HOR_PRED ] = ff_pred8x8l_horizontal_mmxext;
208 h->pred8x8l [
VERT_PRED ] = ff_pred8x8l_vertical_mmxext;
211 h->pred8x8l [
HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_mmxext;
213 h->pred8x8l [
HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_mmxext;
216 h->pred4x4 [
HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_mmxext;
217 h->pred4x4 [
DC_PRED ] = ff_pred4x4_dc_mmxext;
225 h->pred4x4 [
HOR_UP_PRED ] = ff_pred4x4_horizontal_up_mmxext;
228 if (chroma_format_idc == 1) {
230 h->pred8x8[
DC_PRED8x8 ] = ff_pred8x8_dc_mmxext;
235 h->pred8x8 [
DC_PRED8x8 ] = ff_pred8x8_dc_rv40_mmxext;
237 h->pred4x4 [
TM_VP8_PRED ] = ff_pred4x4_tm_vp8_mmxext;
238 h->pred4x4 [
VERT_PRED ] = ff_pred4x4_vertical_vp8_mmxext;
240 if (chroma_format_idc == 1)
257 h->pred16x16[
DC_PRED8x8 ] = ff_pred16x16_dc_sse2;
262 h->pred8x8l [
HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_sse2;
267 if (chroma_format_idc == 1)
280 h->pred16x16[
HOR_PRED8x8 ] = ff_pred16x16_horizontal_ssse3;
281 h->pred16x16[
DC_PRED8x8 ] = ff_pred16x16_dc_ssse3;
282 if (chroma_format_idc == 1)
283 h->pred8x8 [
HOR_PRED8x8 ] = ff_pred8x8_horizontal_ssse3;
284 h->pred8x8l [
TOP_DC_PRED ] = ff_pred8x8l_top_dc_ssse3;
285 h->pred8x8l [
DC_PRED ] = ff_pred8x8l_dc_ssse3;
286 h->pred8x8l [
HOR_PRED ] = ff_pred8x8l_horizontal_ssse3;
287 h->pred8x8l [
VERT_PRED ] = ff_pred8x8l_vertical_ssse3;
292 h->pred8x8l [
HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_ssse3;
293 h->pred8x8l [
HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_ssse3;
296 h->pred4x4 [
TM_VP8_PRED ] = ff_pred4x4_tm_vp8_ssse3;
298 if (chroma_format_idc == 1)
309 }
else if (bit_depth == 10) {
311 h->pred4x4[
DC_PRED ] = ff_pred4x4_dc_10_mmxext;
312 h->pred4x4[
HOR_UP_PRED ] = ff_pred4x4_horizontal_up_10_mmxext;
314 if (chroma_format_idc == 1)
315 h->pred8x8[
DC_PRED8x8 ] = ff_pred8x8_dc_10_mmxext;
317 h->pred8x8l[
DC_128_PRED ] = ff_pred8x8l_128_dc_10_mmxext;
319 h->pred16x16[
DC_PRED8x8 ] = ff_pred16x16_dc_10_mmxext;
323 h->pred16x16[
VERT_PRED8x8 ] = ff_pred16x16_vertical_10_mmxext;
324 h->pred16x16[
HOR_PRED8x8 ] = ff_pred16x16_horizontal_10_mmxext;
331 h->pred4x4[
HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_sse2;
333 if (chroma_format_idc == 1) {
334 h->pred8x8[
DC_PRED8x8 ] = ff_pred8x8_dc_10_sse2;
337 h->pred8x8[
VERT_PRED8x8 ] = ff_pred8x8_vertical_10_sse2;
338 h->pred8x8[
HOR_PRED8x8 ] = ff_pred8x8_horizontal_10_sse2;
341 h->pred8x8l[
VERT_PRED ] = ff_pred8x8l_vertical_10_sse2;
342 h->pred8x8l[
HOR_PRED ] = ff_pred8x8l_horizontal_10_sse2;
343 h->pred8x8l[
DC_PRED ] = ff_pred8x8l_dc_10_sse2;
344 h->pred8x8l[
DC_128_PRED ] = ff_pred8x8l_128_dc_10_sse2;
345 h->pred8x8l[
TOP_DC_PRED ] = ff_pred8x8l_top_dc_10_sse2;
349 h->pred8x8l[
HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_sse2;
351 h->pred16x16[
DC_PRED8x8 ] = ff_pred16x16_dc_10_sse2;
355 h->pred16x16[
VERT_PRED8x8 ] = ff_pred16x16_vertical_10_sse2;
356 h->pred16x16[
HOR_PRED8x8 ] = ff_pred16x16_horizontal_10_sse2;
361 h->pred4x4[
HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_ssse3;
363 h->pred8x8l[
HOR_PRED ] = ff_pred8x8l_horizontal_10_ssse3;
367 h->pred8x8l[
HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_ssse3;
375 h->pred4x4[
HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_avx;
377 h->pred8x8l[
VERT_PRED ] = ff_pred8x8l_vertical_10_avx;
378 h->pred8x8l[
HOR_PRED ] = ff_pred8x8l_horizontal_10_avx;
379 h->pred8x8l[
DC_PRED ] = ff_pred8x8l_dc_10_avx;
380 h->pred8x8l[
TOP_DC_PRED ] = ff_pred8x8l_top_dc_10_avx;
384 h->pred8x8l[
HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_avx;