• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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, 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)
jsimd_can_rgb_ycc(void)23 jsimd_can_rgb_ycc (void)
24 {
25   return 0;
26 }
27 
28 GLOBAL(int)
jsimd_can_rgb_gray(void)29 jsimd_can_rgb_gray (void)
30 {
31   return 0;
32 }
33 
34 GLOBAL(int)
jsimd_can_ycc_rgb(void)35 jsimd_can_ycc_rgb (void)
36 {
37   return 0;
38 }
39 
40 GLOBAL(int)
jsimd_can_ycc_rgb565(void)41 jsimd_can_ycc_rgb565 (void)
42 {
43   return 0;
44 }
45 
46 GLOBAL(int)
jsimd_c_can_null_convert(void)47 jsimd_c_can_null_convert (void)
48 {
49   return 0;
50 }
51 
52 GLOBAL(void)
jsimd_rgb_ycc_convert(j_compress_ptr cinfo,JSAMPARRAY input_buf,JSAMPIMAGE output_buf,JDIMENSION output_row,int num_rows)53 jsimd_rgb_ycc_convert (j_compress_ptr cinfo,
54                        JSAMPARRAY input_buf, JSAMPIMAGE output_buf,
55                        JDIMENSION output_row, int num_rows)
56 {
57 }
58 
59 GLOBAL(void)
jsimd_rgb_gray_convert(j_compress_ptr cinfo,JSAMPARRAY input_buf,JSAMPIMAGE output_buf,JDIMENSION output_row,int num_rows)60 jsimd_rgb_gray_convert (j_compress_ptr cinfo,
61                         JSAMPARRAY input_buf, JSAMPIMAGE output_buf,
62                         JDIMENSION output_row, int num_rows)
63 {
64 }
65 
66 GLOBAL(void)
jsimd_ycc_rgb_convert(j_decompress_ptr cinfo,JSAMPIMAGE input_buf,JDIMENSION input_row,JSAMPARRAY output_buf,int num_rows)67 jsimd_ycc_rgb_convert (j_decompress_ptr cinfo,
68                        JSAMPIMAGE input_buf, JDIMENSION input_row,
69                        JSAMPARRAY output_buf, int num_rows)
70 {
71 }
72 
73 GLOBAL(void)
jsimd_ycc_rgb565_convert(j_decompress_ptr cinfo,JSAMPIMAGE input_buf,JDIMENSION input_row,JSAMPARRAY output_buf,int num_rows)74 jsimd_ycc_rgb565_convert (j_decompress_ptr cinfo,
75                           JSAMPIMAGE input_buf, JDIMENSION input_row,
76                           JSAMPARRAY output_buf, int num_rows)
77 {
78 }
79 
80 GLOBAL(void)
jsimd_c_null_convert(j_compress_ptr cinfo,JSAMPARRAY input_buf,JSAMPIMAGE output_buf,JDIMENSION output_row,int num_rows)81 jsimd_c_null_convert (j_compress_ptr cinfo,
82                       JSAMPARRAY input_buf, JSAMPIMAGE output_buf,
83                       JDIMENSION output_row, int num_rows)
84 {
85 }
86 
87 GLOBAL(int)
jsimd_can_h2v2_downsample(void)88 jsimd_can_h2v2_downsample (void)
89 {
90   return 0;
91 }
92 
93 GLOBAL(int)
jsimd_can_h2v1_downsample(void)94 jsimd_can_h2v1_downsample (void)
95 {
96   return 0;
97 }
98 
99 GLOBAL(int)
jsimd_can_h2v2_smooth_downsample(void)100 jsimd_can_h2v2_smooth_downsample (void)
101 {
102   return 0;
103 }
104 
105 GLOBAL(void)
jsimd_h2v2_downsample(j_compress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY output_data)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)
jsimd_h2v2_smooth_downsample(j_compress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY output_data)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)
jsimd_h2v1_downsample(j_compress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY output_data)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)
jsimd_can_h2v2_upsample(void)125 jsimd_can_h2v2_upsample (void)
126 {
127   return 0;
128 }
129 
130 GLOBAL(int)
jsimd_can_h2v1_upsample(void)131 jsimd_can_h2v1_upsample (void)
132 {
133   return 0;
134 }
135 
136 GLOBAL(int)
jsimd_can_int_upsample(void)137 jsimd_can_int_upsample (void)
138 {
139   return 0;
140 }
141 
142 GLOBAL(void)
jsimd_int_upsample(j_decompress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY * output_data_ptr)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)
jsimd_h2v2_upsample(j_decompress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY * output_data_ptr)149 jsimd_h2v2_upsample (j_decompress_ptr cinfo,
150                      jpeg_component_info *compptr,
151                      JSAMPARRAY input_data,
152                      JSAMPARRAY *output_data_ptr)
153 {
154 }
155 
156 GLOBAL(void)
jsimd_h2v1_upsample(j_decompress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY * output_data_ptr)157 jsimd_h2v1_upsample (j_decompress_ptr cinfo,
158                      jpeg_component_info *compptr,
159                      JSAMPARRAY input_data,
160                      JSAMPARRAY *output_data_ptr)
161 {
162 }
163 
164 GLOBAL(int)
jsimd_can_h2v2_fancy_upsample(void)165 jsimd_can_h2v2_fancy_upsample (void)
166 {
167   return 0;
168 }
169 
170 GLOBAL(int)
jsimd_can_h2v1_fancy_upsample(void)171 jsimd_can_h2v1_fancy_upsample (void)
172 {
173   return 0;
174 }
175 
176 GLOBAL(void)
jsimd_h2v2_fancy_upsample(j_decompress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY * output_data_ptr)177 jsimd_h2v2_fancy_upsample (j_decompress_ptr cinfo,
178                            jpeg_component_info *compptr,
179                            JSAMPARRAY input_data,
180                            JSAMPARRAY *output_data_ptr)
181 {
182 }
183 
184 GLOBAL(void)
jsimd_h2v1_fancy_upsample(j_decompress_ptr cinfo,jpeg_component_info * compptr,JSAMPARRAY input_data,JSAMPARRAY * output_data_ptr)185 jsimd_h2v1_fancy_upsample (j_decompress_ptr cinfo,
186                            jpeg_component_info *compptr,
187                            JSAMPARRAY input_data,
188                            JSAMPARRAY *output_data_ptr)
189 {
190 }
191 
192 GLOBAL(int)
jsimd_can_h2v2_merged_upsample(void)193 jsimd_can_h2v2_merged_upsample (void)
194 {
195   return 0;
196 }
197 
198 GLOBAL(int)
jsimd_can_h2v1_merged_upsample(void)199 jsimd_can_h2v1_merged_upsample (void)
200 {
201   return 0;
202 }
203 
204 GLOBAL(void)
jsimd_h2v2_merged_upsample(j_decompress_ptr cinfo,JSAMPIMAGE input_buf,JDIMENSION in_row_group_ctr,JSAMPARRAY output_buf)205 jsimd_h2v2_merged_upsample (j_decompress_ptr cinfo,
206                             JSAMPIMAGE input_buf,
207                             JDIMENSION in_row_group_ctr,
208                             JSAMPARRAY output_buf)
209 {
210 }
211 
212 GLOBAL(void)
jsimd_h2v1_merged_upsample(j_decompress_ptr cinfo,JSAMPIMAGE input_buf,JDIMENSION in_row_group_ctr,JSAMPARRAY output_buf)213 jsimd_h2v1_merged_upsample (j_decompress_ptr cinfo,
214                             JSAMPIMAGE input_buf,
215                             JDIMENSION in_row_group_ctr,
216                             JSAMPARRAY output_buf)
217 {
218 }
219 
220 GLOBAL(int)
jsimd_can_convsamp(void)221 jsimd_can_convsamp (void)
222 {
223   return 0;
224 }
225 
226 GLOBAL(int)
jsimd_can_convsamp_float(void)227 jsimd_can_convsamp_float (void)
228 {
229   return 0;
230 }
231 
232 GLOBAL(void)
jsimd_convsamp(JSAMPARRAY sample_data,JDIMENSION start_col,DCTELEM * workspace)233 jsimd_convsamp (JSAMPARRAY sample_data, JDIMENSION start_col,
234                 DCTELEM *workspace)
235 {
236 }
237 
238 GLOBAL(void)
jsimd_convsamp_float(JSAMPARRAY sample_data,JDIMENSION start_col,FAST_FLOAT * workspace)239 jsimd_convsamp_float (JSAMPARRAY sample_data, JDIMENSION start_col,
240                       FAST_FLOAT *workspace)
241 {
242 }
243 
244 GLOBAL(int)
jsimd_can_fdct_islow(void)245 jsimd_can_fdct_islow (void)
246 {
247   return 0;
248 }
249 
250 GLOBAL(int)
jsimd_can_fdct_ifast(void)251 jsimd_can_fdct_ifast (void)
252 {
253   return 0;
254 }
255 
256 GLOBAL(int)
jsimd_can_fdct_float(void)257 jsimd_can_fdct_float (void)
258 {
259   return 0;
260 }
261 
262 GLOBAL(void)
jsimd_fdct_islow(DCTELEM * data)263 jsimd_fdct_islow (DCTELEM *data)
264 {
265 }
266 
267 GLOBAL(void)
jsimd_fdct_ifast(DCTELEM * data)268 jsimd_fdct_ifast (DCTELEM *data)
269 {
270 }
271 
272 GLOBAL(void)
jsimd_fdct_float(FAST_FLOAT * data)273 jsimd_fdct_float (FAST_FLOAT *data)
274 {
275 }
276 
277 GLOBAL(int)
jsimd_can_quantize(void)278 jsimd_can_quantize (void)
279 {
280   return 0;
281 }
282 
283 GLOBAL(int)
jsimd_can_quantize_float(void)284 jsimd_can_quantize_float (void)
285 {
286   return 0;
287 }
288 
289 GLOBAL(void)
jsimd_quantize(JCOEFPTR coef_block,DCTELEM * divisors,DCTELEM * workspace)290 jsimd_quantize (JCOEFPTR coef_block, DCTELEM *divisors,
291                 DCTELEM *workspace)
292 {
293 }
294 
295 GLOBAL(void)
jsimd_quantize_float(JCOEFPTR coef_block,FAST_FLOAT * divisors,FAST_FLOAT * workspace)296 jsimd_quantize_float (JCOEFPTR coef_block, FAST_FLOAT *divisors,
297                       FAST_FLOAT *workspace)
298 {
299 }
300 
301 GLOBAL(int)
jsimd_can_idct_2x2(void)302 jsimd_can_idct_2x2 (void)
303 {
304   return 0;
305 }
306 
307 GLOBAL(int)
jsimd_can_idct_4x4(void)308 jsimd_can_idct_4x4 (void)
309 {
310   return 0;
311 }
312 
313 GLOBAL(int)
jsimd_can_idct_6x6(void)314 jsimd_can_idct_6x6 (void)
315 {
316   return 0;
317 }
318 
319 GLOBAL(int)
jsimd_can_idct_12x12(void)320 jsimd_can_idct_12x12 (void)
321 {
322   return 0;
323 }
324 
325 GLOBAL(void)
jsimd_idct_2x2(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)326 jsimd_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
327                 JCOEFPTR coef_block, JSAMPARRAY output_buf,
328                 JDIMENSION output_col)
329 {
330 }
331 
332 GLOBAL(void)
jsimd_idct_4x4(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)333 jsimd_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
334                 JCOEFPTR coef_block, JSAMPARRAY output_buf,
335                 JDIMENSION output_col)
336 {
337 }
338 
339 GLOBAL(void)
jsimd_idct_6x6(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)340 jsimd_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
341                 JCOEFPTR coef_block, JSAMPARRAY output_buf,
342                 JDIMENSION output_col)
343 {
344 }
345 
346 GLOBAL(void)
jsimd_idct_12x12(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)347 jsimd_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
348                   JCOEFPTR coef_block, JSAMPARRAY output_buf,
349                   JDIMENSION output_col)
350 {
351 }
352 
353 GLOBAL(int)
jsimd_can_idct_islow(void)354 jsimd_can_idct_islow (void)
355 {
356   return 0;
357 }
358 
359 GLOBAL(int)
jsimd_can_idct_ifast(void)360 jsimd_can_idct_ifast (void)
361 {
362   return 0;
363 }
364 
365 GLOBAL(int)
jsimd_can_idct_float(void)366 jsimd_can_idct_float (void)
367 {
368   return 0;
369 }
370 
371 GLOBAL(void)
jsimd_idct_islow(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)372 jsimd_idct_islow (j_decompress_ptr cinfo, jpeg_component_info *compptr,
373                   JCOEFPTR coef_block, JSAMPARRAY output_buf,
374                   JDIMENSION output_col)
375 {
376 }
377 
378 GLOBAL(void)
jsimd_idct_ifast(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)379 jsimd_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info *compptr,
380                   JCOEFPTR coef_block, JSAMPARRAY output_buf,
381                   JDIMENSION output_col)
382 {
383 }
384 
385 GLOBAL(void)
jsimd_idct_float(j_decompress_ptr cinfo,jpeg_component_info * compptr,JCOEFPTR coef_block,JSAMPARRAY output_buf,JDIMENSION output_col)386 jsimd_idct_float (j_decompress_ptr cinfo, jpeg_component_info *compptr,
387                   JCOEFPTR coef_block, JSAMPARRAY output_buf,
388                   JDIMENSION output_col)
389 {
390 }
391 
392 GLOBAL(int)
jsimd_can_huff_encode_one_block(void)393 jsimd_can_huff_encode_one_block (void)
394 {
395   return 0;
396 }
397 
398 GLOBAL(JOCTET*)
jsimd_huff_encode_one_block(void * state,JOCTET * buffer,JCOEFPTR block,int last_dc_val,c_derived_tbl * dctbl,c_derived_tbl * actbl)399 jsimd_huff_encode_one_block (void *state, JOCTET *buffer, JCOEFPTR block,
400                              int last_dc_val, c_derived_tbl *dctbl,
401                              c_derived_tbl *actbl)
402 {
403   return NULL;
404 }
405