1 /*
2 * This file is part of FFmpeg.
3 *
4 * FFmpeg is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * FFmpeg is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with FFmpeg; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
17 */
18
19 #include <string.h>
20
25
28
30
31 #define randomize_buffers(buf, size) \
32 do { \
33 for (int j = 0; j < size; j += 4) \
34 AV_WN32(buf + j, rnd()); \
35 } while (0)
36
38 {
39 static const int src_fmts[] = {
42 };
44 #define NUM_LINES 4
45 #define MAX_LINE_SIZE 1920
47
50 const int srcStride[], int srcSliceY, int srcSliceH,
51 uint8_t *const dstParam[], const int dstStride[]);
52
55 const uint8_t *
src[4] = { src_y, src_uv };
56
60 uint8_t *dst0[4] = { dst0_y, dst0_u, dst0_v };
61
65 uint8_t *dst1[4] = { dst1_y, dst1_u, dst1_v };
66
69
71 int src_pix_fmt = src_fmts[sfi];
76 int log_level;
78 int srcSliceY = 0;
80 int srcStride[4] = {
83 };
84 int dstStride[4] = {
88 };
89
90 // override log level to prevent spamming of the message
91 // "No accelerated colorspace conversion found from %s to %s"
95 width, srcSliceH, dst_pix_fmt,
100
109
111 srcSliceH, dst0, dstStride);
113 srcSliceH, dst1, dstStride);
114
119
121 srcSliceH, dst0, dstStride);
122 }
124 }
125 }
126 }
127
128 #undef NUM_LINES
129 #undef MAX_LINE_SIZE
130
132 {
135 }