1 | /* |
2 | * jsimd_none.c |
3 | * |
4 | * Copyright 2009 Pierre Ossman <ossman@cendio.se> for Cendio AB |
5 | * Copyright (C) 2009-2011, 2014, D. R. Commander. |
6 | * Copyright (C) 2015-2016, 2018, Matthieu Darbois. |
7 | * |
8 | * Based on the x86 SIMD extension for IJG JPEG library, |
9 | * Copyright (C) 1999-2006, MIYASAKA Masaru. |
10 | * For conditions of distribution and use, see copyright notice in jsimdext.inc |
11 | * |
12 | * This file contains stubs for when there is no SIMD support available. |
13 | */ |
14 | |
15 | #define JPEG_INTERNALS |
16 | #include "jinclude.h" |
17 | #include "jpeglib.h" |
18 | #include "jsimd.h" |
19 | #include "jdct.h" |
20 | #include "jsimddct.h" |
21 | |
22 | GLOBAL(int) |
23 | jsimd_can_rgb_ycc(void) |
24 | { |
25 | return 0; |
26 | } |
27 | |
28 | GLOBAL(int) |
29 | jsimd_can_rgb_gray(void) |
30 | { |
31 | return 0; |
32 | } |
33 | |
34 | GLOBAL(int) |
35 | jsimd_can_ycc_rgb(void) |
36 | { |
37 | return 0; |
38 | } |
39 | |
40 | GLOBAL(int) |
41 | jsimd_can_ycc_rgb565(void) |
42 | { |
43 | return 0; |
44 | } |
45 | |
46 | GLOBAL(int) |
47 | jsimd_c_can_null_convert(void) |
48 | { |
49 | return 0; |
50 | } |
51 | |
52 | GLOBAL(void) |
53 | jsimd_rgb_ycc_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf, |
54 | JSAMPIMAGE output_buf, JDIMENSION output_row, |
55 | int num_rows) |
56 | { |
57 | } |
58 | |
59 | GLOBAL(void) |
60 | jsimd_rgb_gray_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf, |
61 | JSAMPIMAGE output_buf, JDIMENSION output_row, |
62 | int num_rows) |
63 | { |
64 | } |
65 | |
66 | GLOBAL(void) |
67 | jsimd_ycc_rgb_convert(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, |
68 | JDIMENSION input_row, JSAMPARRAY output_buf, |
69 | int num_rows) |
70 | { |
71 | } |
72 | |
73 | GLOBAL(void) |
74 | jsimd_ycc_rgb565_convert(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, |
75 | JDIMENSION input_row, JSAMPARRAY output_buf, |
76 | int num_rows) |
77 | { |
78 | } |
79 | |
80 | GLOBAL(void) |
81 | jsimd_c_null_convert(j_compress_ptr cinfo, JSAMPARRAY input_buf, |
82 | JSAMPIMAGE output_buf, JDIMENSION output_row, |
83 | int num_rows) |
84 | { |
85 | } |
86 | |
87 | GLOBAL(int) |
88 | jsimd_can_h2v2_downsample(void) |
89 | { |
90 | return 0; |
91 | } |
92 | |
93 | GLOBAL(int) |
94 | jsimd_can_h2v1_downsample(void) |
95 | { |
96 | return 0; |
97 | } |
98 | |
99 | GLOBAL(int) |
100 | jsimd_can_h2v2_smooth_downsample(void) |
101 | { |
102 | return 0; |
103 | } |
104 | |
105 | GLOBAL(void) |
106 | jsimd_h2v2_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr, |
107 | JSAMPARRAY input_data, JSAMPARRAY output_data) |
108 | { |
109 | } |
110 | |
111 | GLOBAL(void) |
112 | jsimd_h2v2_smooth_downsample(j_compress_ptr cinfo, |
113 | jpeg_component_info *compptr, |
114 | JSAMPARRAY input_data, JSAMPARRAY output_data) |
115 | { |
116 | } |
117 | |
118 | GLOBAL(void) |
119 | jsimd_h2v1_downsample(j_compress_ptr cinfo, jpeg_component_info *compptr, |
120 | JSAMPARRAY input_data, JSAMPARRAY output_data) |
121 | { |
122 | } |
123 | |
124 | GLOBAL(int) |
125 | jsimd_can_h2v2_upsample(void) |
126 | { |
127 | return 0; |
128 | } |
129 | |
130 | GLOBAL(int) |
131 | jsimd_can_h2v1_upsample(void) |
132 | { |
133 | return 0; |
134 | } |
135 | |
136 | GLOBAL(int) |
137 | jsimd_can_int_upsample(void) |
138 | { |
139 | return 0; |
140 | } |
141 | |
142 | GLOBAL(void) |
143 | jsimd_int_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
144 | JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr) |
145 | { |
146 | } |
147 | |
148 | GLOBAL(void) |
149 | jsimd_h2v2_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
150 | JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr) |
151 | { |
152 | } |
153 | |
154 | GLOBAL(void) |
155 | jsimd_h2v1_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
156 | JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr) |
157 | { |
158 | } |
159 | |
160 | GLOBAL(int) |
161 | jsimd_can_h2v2_fancy_upsample(void) |
162 | { |
163 | return 0; |
164 | } |
165 | |
166 | GLOBAL(int) |
167 | jsimd_can_h2v1_fancy_upsample(void) |
168 | { |
169 | return 0; |
170 | } |
171 | |
172 | GLOBAL(void) |
173 | jsimd_h2v2_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
174 | JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr) |
175 | { |
176 | } |
177 | |
178 | GLOBAL(void) |
179 | jsimd_h2v1_fancy_upsample(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
180 | JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr) |
181 | { |
182 | } |
183 | |
184 | GLOBAL(int) |
185 | jsimd_can_h2v2_merged_upsample(void) |
186 | { |
187 | return 0; |
188 | } |
189 | |
190 | GLOBAL(int) |
191 | jsimd_can_h2v1_merged_upsample(void) |
192 | { |
193 | return 0; |
194 | } |
195 | |
196 | GLOBAL(void) |
197 | jsimd_h2v2_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, |
198 | JDIMENSION in_row_group_ctr, JSAMPARRAY output_buf) |
199 | { |
200 | } |
201 | |
202 | GLOBAL(void) |
203 | jsimd_h2v1_merged_upsample(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, |
204 | JDIMENSION in_row_group_ctr, JSAMPARRAY output_buf) |
205 | { |
206 | } |
207 | |
208 | GLOBAL(int) |
209 | jsimd_can_convsamp(void) |
210 | { |
211 | return 0; |
212 | } |
213 | |
214 | GLOBAL(int) |
215 | jsimd_can_convsamp_float(void) |
216 | { |
217 | return 0; |
218 | } |
219 | |
220 | GLOBAL(void) |
221 | jsimd_convsamp(JSAMPARRAY sample_data, JDIMENSION start_col, |
222 | DCTELEM *workspace) |
223 | { |
224 | } |
225 | |
226 | GLOBAL(void) |
227 | jsimd_convsamp_float(JSAMPARRAY sample_data, JDIMENSION start_col, |
228 | FAST_FLOAT *workspace) |
229 | { |
230 | } |
231 | |
232 | GLOBAL(int) |
233 | jsimd_can_fdct_islow(void) |
234 | { |
235 | return 0; |
236 | } |
237 | |
238 | GLOBAL(int) |
239 | jsimd_can_fdct_ifast(void) |
240 | { |
241 | return 0; |
242 | } |
243 | |
244 | GLOBAL(int) |
245 | jsimd_can_fdct_float(void) |
246 | { |
247 | return 0; |
248 | } |
249 | |
250 | GLOBAL(void) |
251 | jsimd_fdct_islow(DCTELEM *data) |
252 | { |
253 | } |
254 | |
255 | GLOBAL(void) |
256 | jsimd_fdct_ifast(DCTELEM *data) |
257 | { |
258 | } |
259 | |
260 | GLOBAL(void) |
261 | jsimd_fdct_float(FAST_FLOAT *data) |
262 | { |
263 | } |
264 | |
265 | GLOBAL(int) |
266 | jsimd_can_quantize(void) |
267 | { |
268 | return 0; |
269 | } |
270 | |
271 | GLOBAL(int) |
272 | jsimd_can_quantize_float(void) |
273 | { |
274 | return 0; |
275 | } |
276 | |
277 | GLOBAL(void) |
278 | jsimd_quantize(JCOEFPTR coef_block, DCTELEM *divisors, DCTELEM *workspace) |
279 | { |
280 | } |
281 | |
282 | GLOBAL(void) |
283 | jsimd_quantize_float(JCOEFPTR coef_block, FAST_FLOAT *divisors, |
284 | FAST_FLOAT *workspace) |
285 | { |
286 | } |
287 | |
288 | GLOBAL(int) |
289 | jsimd_can_idct_2x2(void) |
290 | { |
291 | return 0; |
292 | } |
293 | |
294 | GLOBAL(int) |
295 | jsimd_can_idct_4x4(void) |
296 | { |
297 | return 0; |
298 | } |
299 | |
300 | GLOBAL(int) |
301 | jsimd_can_idct_6x6(void) |
302 | { |
303 | return 0; |
304 | } |
305 | |
306 | GLOBAL(int) |
307 | jsimd_can_idct_12x12(void) |
308 | { |
309 | return 0; |
310 | } |
311 | |
312 | GLOBAL(void) |
313 | jsimd_idct_2x2(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
314 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
315 | JDIMENSION output_col) |
316 | { |
317 | } |
318 | |
319 | GLOBAL(void) |
320 | jsimd_idct_4x4(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
321 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
322 | JDIMENSION output_col) |
323 | { |
324 | } |
325 | |
326 | GLOBAL(void) |
327 | jsimd_idct_6x6(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
328 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
329 | JDIMENSION output_col) |
330 | { |
331 | } |
332 | |
333 | GLOBAL(void) |
334 | jsimd_idct_12x12(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
335 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
336 | JDIMENSION output_col) |
337 | { |
338 | } |
339 | |
340 | GLOBAL(int) |
341 | jsimd_can_idct_islow(void) |
342 | { |
343 | return 0; |
344 | } |
345 | |
346 | GLOBAL(int) |
347 | jsimd_can_idct_ifast(void) |
348 | { |
349 | return 0; |
350 | } |
351 | |
352 | GLOBAL(int) |
353 | jsimd_can_idct_float(void) |
354 | { |
355 | return 0; |
356 | } |
357 | |
358 | GLOBAL(void) |
359 | jsimd_idct_islow(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
360 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
361 | JDIMENSION output_col) |
362 | { |
363 | } |
364 | |
365 | GLOBAL(void) |
366 | jsimd_idct_ifast(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
367 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
368 | JDIMENSION output_col) |
369 | { |
370 | } |
371 | |
372 | GLOBAL(void) |
373 | jsimd_idct_float(j_decompress_ptr cinfo, jpeg_component_info *compptr, |
374 | JCOEFPTR coef_block, JSAMPARRAY output_buf, |
375 | JDIMENSION output_col) |
376 | { |
377 | } |
378 | |
379 | GLOBAL(int) |
380 | jsimd_can_huff_encode_one_block(void) |
381 | { |
382 | return 0; |
383 | } |
384 | |
385 | GLOBAL(JOCTET *) |
386 | jsimd_huff_encode_one_block(void *state, JOCTET *buffer, JCOEFPTR block, |
387 | int last_dc_val, c_derived_tbl *dctbl, |
388 | c_derived_tbl *actbl) |
389 | { |
390 | return NULL; |
391 | } |
392 | |
393 | GLOBAL(int) |
394 | jsimd_can_encode_mcu_AC_first_prepare(void) |
395 | { |
396 | return 0; |
397 | } |
398 | |
399 | GLOBAL(void) |
400 | jsimd_encode_mcu_AC_first_prepare(const JCOEF *block, |
401 | const int *jpeg_natural_order_start, int Sl, |
402 | int Al, JCOEF *values, size_t *zerobits) |
403 | { |
404 | } |
405 | |
406 | GLOBAL(int) |
407 | jsimd_can_encode_mcu_AC_refine_prepare(void) |
408 | { |
409 | return 0; |
410 | } |
411 | |
412 | GLOBAL(int) |
413 | jsimd_encode_mcu_AC_refine_prepare(const JCOEF *block, |
414 | const int *jpeg_natural_order_start, int Sl, |
415 | int Al, JCOEF *absvalues, size_t *bits) |
416 | { |
417 | return 0; |
418 | } |
419 | |