33 void ff_put_vp8_epel4_h4_mmxext(
uint8_t *dst, ptrdiff_t dststride,
35 int height,
int mx,
int my);
36 void ff_put_vp8_epel4_h6_mmxext(
uint8_t *dst, ptrdiff_t dststride,
38 int height,
int mx,
int my);
39 void ff_put_vp8_epel4_v4_mmxext(
uint8_t *dst, ptrdiff_t dststride,
41 int height,
int mx,
int my);
42 void ff_put_vp8_epel4_v6_mmxext(
uint8_t *dst, ptrdiff_t dststride,
44 int height,
int mx,
int my);
46 void ff_put_vp8_epel8_h4_sse2 (
uint8_t *dst, ptrdiff_t dststride,
48 int height,
int mx,
int my);
49 void ff_put_vp8_epel8_h6_sse2 (
uint8_t *dst, ptrdiff_t dststride,
51 int height,
int mx,
int my);
52 void ff_put_vp8_epel8_v4_sse2 (
uint8_t *dst, ptrdiff_t dststride,
54 int height,
int mx,
int my);
55 void ff_put_vp8_epel8_v6_sse2 (
uint8_t *dst, ptrdiff_t dststride,
57 int height,
int mx,
int my);
59 void ff_put_vp8_epel4_h4_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
61 int height,
int mx,
int my);
62 void ff_put_vp8_epel4_h6_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
64 int height,
int mx,
int my);
65 void ff_put_vp8_epel4_v4_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
67 int height,
int mx,
int my);
68 void ff_put_vp8_epel4_v6_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
70 int height,
int mx,
int my);
71 void ff_put_vp8_epel8_h4_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
73 int height,
int mx,
int my);
74 void ff_put_vp8_epel8_h6_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
76 int height,
int mx,
int my);
77 void ff_put_vp8_epel8_v4_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
79 int height,
int mx,
int my);
80 void ff_put_vp8_epel8_v6_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
82 int height,
int mx,
int my);
84 void ff_put_vp8_bilinear4_h_mmxext(
uint8_t *dst, ptrdiff_t dststride,
86 int height,
int mx,
int my);
87 void ff_put_vp8_bilinear8_h_sse2 (
uint8_t *dst, ptrdiff_t dststride,
89 int height,
int mx,
int my);
90 void ff_put_vp8_bilinear4_h_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
92 int height,
int mx,
int my);
93 void ff_put_vp8_bilinear8_h_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
95 int height,
int mx,
int my);
97 void ff_put_vp8_bilinear4_v_mmxext(
uint8_t *dst, ptrdiff_t dststride,
99 int height,
int mx,
int my);
100 void ff_put_vp8_bilinear8_v_sse2 (
uint8_t *dst, ptrdiff_t dststride,
102 int height,
int mx,
int my);
103 void ff_put_vp8_bilinear4_v_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
105 int height,
int mx,
int my);
106 void ff_put_vp8_bilinear8_v_ssse3 (
uint8_t *dst, ptrdiff_t dststride,
108 int height,
int mx,
int my);
111 void ff_put_vp8_pixels8_mmx (
uint8_t *dst, ptrdiff_t dststride,
113 int height,
int mx,
int my);
114 void ff_put_vp8_pixels16_mmx(
uint8_t *dst, ptrdiff_t dststride,
116 int height,
int mx,
int my);
117 void ff_put_vp8_pixels16_sse(
uint8_t *dst, ptrdiff_t dststride,
119 int height,
int mx,
int my);
121 #define TAP_W16(OPT, FILTERTYPE, TAPTYPE) \
122 static void ff_put_vp8_ ## FILTERTYPE ## 16_ ## TAPTYPE ## _ ## OPT( \
123 uint8_t *dst, ptrdiff_t dststride, uint8_t *src, \
124 ptrdiff_t srcstride, int height, int mx, int my) \
126 ff_put_vp8_ ## FILTERTYPE ## 8_ ## TAPTYPE ## _ ## OPT( \
127 dst, dststride, src, srcstride, height, mx, my); \
128 ff_put_vp8_ ## FILTERTYPE ## 8_ ## TAPTYPE ## _ ## OPT( \
129 dst + 8, dststride, src + 8, srcstride, height, mx, my); \
131 #define TAP_W8(OPT, FILTERTYPE, TAPTYPE) \
132 static void ff_put_vp8_ ## FILTERTYPE ## 8_ ## TAPTYPE ## _ ## OPT( \
133 uint8_t *dst, ptrdiff_t dststride, uint8_t *src, \
134 ptrdiff_t srcstride, int height, int mx, int my) \
136 ff_put_vp8_ ## FILTERTYPE ## 4_ ## TAPTYPE ## _ ## OPT( \
137 dst, dststride, src, srcstride, height, mx, my); \
138 ff_put_vp8_ ## FILTERTYPE ## 4_ ## TAPTYPE ## _ ## OPT( \
139 dst + 4, dststride, src + 4, srcstride, height, mx, my); \
143 TAP_W8 (mmxext, epel, h4)
144 TAP_W8 (mmxext, epel, h6)
145 TAP_W16(mmxext, epel, h6)
146 TAP_W8 (mmxext, epel, v4)
147 TAP_W8 (mmxext, epel, v6)
148 TAP_W16(mmxext, epel, v6)
149 TAP_W8 (mmxext, bilinear, h)
150 TAP_W16(mmxext, bilinear, h)
151 TAP_W8 (mmxext, bilinear,
v)
152 TAP_W16(mmxext, bilinear,
v)
155 TAP_W16(sse2, epel, h6)
156 TAP_W16(sse2, epel, v6)
157 TAP_W16(sse2, bilinear, h)
158 TAP_W16(sse2, bilinear,
v)
160 TAP_W16(ssse3, epel, h6)
161 TAP_W16(ssse3, epel, v6)
162 TAP_W16(ssse3, bilinear, h)
163 TAP_W16(ssse3, bilinear,
v)
165 #define HVTAP(OPT, ALIGN, TAPNUMX, TAPNUMY, SIZE, MAXHEIGHT) \
166 static void ff_put_vp8_epel ## SIZE ## _h ## TAPNUMX ## v ## TAPNUMY ## _ ## OPT( \
167 uint8_t *dst, ptrdiff_t dststride, uint8_t *src, \
168 ptrdiff_t srcstride, int height, int mx, int my) \
170 DECLARE_ALIGNED(ALIGN, uint8_t, tmp)[SIZE * (MAXHEIGHT + TAPNUMY - 1)]; \
171 uint8_t *tmpptr = tmp + SIZE * (TAPNUMY / 2 - 1); \
172 src -= srcstride * (TAPNUMY / 2 - 1); \
173 ff_put_vp8_epel ## SIZE ## _h ## TAPNUMX ## _ ## OPT( \
174 tmp, SIZE, src, srcstride, height + TAPNUMY - 1, mx, my); \
175 ff_put_vp8_epel ## SIZE ## _v ## TAPNUMY ## _ ## OPT( \
176 dst, dststride, tmpptr, SIZE, height, mx, my); \
180 #define HVTAPMMX(x, y) \
181 HVTAP(mmxext, 8, x, y, 4, 8) \
182 HVTAP(mmxext, 8, x, y, 8, 16)
184 HVTAP(mmxext, 8, 6, 6, 16, 16)
186 #define HVTAPMMX(x, y) \
187 HVTAP(mmxext, 8, x, y, 4, 8)
195 #define HVTAPSSE2(x, y, w) \
196 HVTAP(sse2, 16, x, y, w, 16) \
197 HVTAP(ssse3, 16, x, y, w, 16)
205 HVTAP(ssse3, 16, 4, 4, 4, 8)
206 HVTAP(ssse3, 16, 4, 6, 4, 8)
207 HVTAP(ssse3, 16, 6, 4, 4, 8)
208 HVTAP(ssse3, 16, 6, 6, 4, 8)
210 #define HVBILIN(OPT, ALIGN, SIZE, MAXHEIGHT) \
211 static void ff_put_vp8_bilinear ## SIZE ## _hv_ ## OPT( \
212 uint8_t *dst, ptrdiff_t dststride, uint8_t *src, \
213 ptrdiff_t srcstride, int height, int mx, int my) \
215 DECLARE_ALIGNED(ALIGN, uint8_t, tmp)[SIZE * (MAXHEIGHT + 2)]; \
216 ff_put_vp8_bilinear ## SIZE ## _h_ ## OPT( \
217 tmp, SIZE, src, srcstride, height + 1, mx, my); \
218 ff_put_vp8_bilinear ## SIZE ## _v_ ## OPT( \
219 dst, dststride, tmp, SIZE, height, mx, my); \
222 HVBILIN(mmxext, 8, 4, 8)
224 HVBILIN(mmxext, 8, 8, 16)
225 HVBILIN(mmxext, 8, 16, 16)
227 HVBILIN(sse2, 8, 8, 16)
228 HVBILIN(sse2, 8, 16, 16)
229 HVBILIN(ssse3, 8, 4, 8)
230 HVBILIN(ssse3, 8, 8, 16)
231 HVBILIN(ssse3, 8, 16, 16)
233 void ff_vp8_idct_dc_add_mmx(
uint8_t *dst, int16_t
block[16],
235 void ff_vp8_idct_dc_add_sse4(
uint8_t *dst, int16_t block[16],
237 void ff_vp8_idct_dc_add4y_mmx(
uint8_t *dst, int16_t block[4][16],
239 void ff_vp8_idct_dc_add4y_sse2(
uint8_t *dst, int16_t block[4][16],
241 void ff_vp8_idct_dc_add4uv_mmx(
uint8_t *dst, int16_t block[2][16],
243 void ff_vp8_luma_dc_wht_mmx(int16_t block[4][4][16], int16_t
dc[16]);
244 void ff_vp8_luma_dc_wht_sse(int16_t block[4][4][16], int16_t dc[16]);
245 void ff_vp8_idct_add_mmx(
uint8_t *dst, int16_t block[16], ptrdiff_t stride);
246 void ff_vp8_idct_add_sse(
uint8_t *dst, int16_t block[16], ptrdiff_t stride);
248 #define DECLARE_LOOP_FILTER(NAME) \
249 void ff_vp8_v_loop_filter_simple_ ## NAME(uint8_t *dst, \
252 void ff_vp8_h_loop_filter_simple_ ## NAME(uint8_t *dst, \
255 void ff_vp8_v_loop_filter16y_inner_ ## NAME (uint8_t *dst, \
257 int e, int i, int hvt); \
258 void ff_vp8_h_loop_filter16y_inner_ ## NAME (uint8_t *dst, \
260 int e, int i, int hvt); \
261 void ff_vp8_v_loop_filter8uv_inner_ ## NAME (uint8_t *dstU, \
264 int e, int i, int hvt); \
265 void ff_vp8_h_loop_filter8uv_inner_ ## NAME (uint8_t *dstU, \
268 int e, int i, int hvt); \
269 void ff_vp8_v_loop_filter16y_mbedge_ ## NAME(uint8_t *dst, \
271 int e, int i, int hvt); \
272 void ff_vp8_h_loop_filter16y_mbedge_ ## NAME(uint8_t *dst, \
274 int e, int i, int hvt); \
275 void ff_vp8_v_loop_filter8uv_mbedge_ ## NAME(uint8_t *dstU, \
278 int e, int i, int hvt); \
279 void ff_vp8_h_loop_filter8uv_mbedge_ ## NAME(uint8_t *dstU, \
282 int e, int i, int hvt);
284 DECLARE_LOOP_FILTER(mmx)
285 DECLARE_LOOP_FILTER(mmxext)
286 DECLARE_LOOP_FILTER(sse2)
287 DECLARE_LOOP_FILTER(ssse3)
288 DECLARE_LOOP_FILTER(sse4)
292 #define VP8_LUMA_MC_FUNC(IDX, SIZE, OPT) \
293 c->put_vp8_epel_pixels_tab[IDX][0][2] = ff_put_vp8_epel ## SIZE ## _h6_ ## OPT; \
294 c->put_vp8_epel_pixels_tab[IDX][2][0] = ff_put_vp8_epel ## SIZE ## _v6_ ## OPT; \
295 c->put_vp8_epel_pixels_tab[IDX][2][2] = ff_put_vp8_epel ## SIZE ## _h6v6_ ## OPT
297 #define VP8_MC_FUNC(IDX, SIZE, OPT) \
298 c->put_vp8_epel_pixels_tab[IDX][0][1] = ff_put_vp8_epel ## SIZE ## _h4_ ## OPT; \
299 c->put_vp8_epel_pixels_tab[IDX][1][0] = ff_put_vp8_epel ## SIZE ## _v4_ ## OPT; \
300 c->put_vp8_epel_pixels_tab[IDX][1][1] = ff_put_vp8_epel ## SIZE ## _h4v4_ ## OPT; \
301 c->put_vp8_epel_pixels_tab[IDX][1][2] = ff_put_vp8_epel ## SIZE ## _h6v4_ ## OPT; \
302 c->put_vp8_epel_pixels_tab[IDX][2][1] = ff_put_vp8_epel ## SIZE ## _h4v6_ ## OPT; \
303 VP8_LUMA_MC_FUNC(IDX, SIZE, OPT)
305 #define VP8_BILINEAR_MC_FUNC(IDX, SIZE, OPT) \
306 c->put_vp8_bilinear_pixels_tab[IDX][0][1] = ff_put_vp8_bilinear ## SIZE ## _h_ ## OPT; \
307 c->put_vp8_bilinear_pixels_tab[IDX][0][2] = ff_put_vp8_bilinear ## SIZE ## _h_ ## OPT; \
308 c->put_vp8_bilinear_pixels_tab[IDX][1][0] = ff_put_vp8_bilinear ## SIZE ## _v_ ## OPT; \
309 c->put_vp8_bilinear_pixels_tab[IDX][1][1] = ff_put_vp8_bilinear ## SIZE ## _hv_ ## OPT; \
310 c->put_vp8_bilinear_pixels_tab[IDX][1][2] = ff_put_vp8_bilinear ## SIZE ## _hv_ ## OPT; \
311 c->put_vp8_bilinear_pixels_tab[IDX][2][0] = ff_put_vp8_bilinear ## SIZE ## _v_ ## OPT; \
312 c->put_vp8_bilinear_pixels_tab[IDX][2][1] = ff_put_vp8_bilinear ## SIZE ## _hv_ ## OPT; \
313 c->put_vp8_bilinear_pixels_tab[IDX][2][2] = ff_put_vp8_bilinear ## SIZE ## _hv_ ## OPT