Ocean
TestSSE.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) Meta Platforms, Inc. and affiliates.
3  *
4  * This source code is licensed under the MIT license found in the
5  * LICENSE file in the root directory of this source tree.
6  */
7 
8 #ifndef META_OCEAN_TEST_TESTCV_TEST_SSE_H
9 #define META_OCEAN_TEST_TESTCV_TEST_SSE_H
10 
12 
13 #if defined(OCEAN_HARDWARE_SSE_VERSION) && OCEAN_HARDWARE_SSE_VERSION >= 41
14 
15 namespace Ocean
16 {
17 
18 namespace Test
19 {
20 
21 namespace TestCV
22 {
23 
24 /**
25  * This class implements a Computer Vision SSE test.
26  * @ingroup testcv
27  */
28 class OCEAN_TEST_CV_EXPORT TestSSE
29 {
30  public:
31 
32  /**
33  * Tests the entire SSE class.
34  * @param testDuration Number of seconds for each test, with range (0, infinity)
35  * @return True, if succeeded
36  */
37  static bool test(const double testDuration);
38 
39  /*
40  * Tests the SSE averaging functions for 1 channel 8 bit.
41  * @param testDuration Number of seconds for each test, with range (0, infinity)
42  * @return True, if all result are valid
43  */
44  static bool testAveraging1Channel8Bit2x2(const double testDuration);
45 
46  /*
47  * Tests the SSE averaging functions for 1 channel 8 bit.
48  * @param testDuration Number of seconds for each test, with range (0, infinity)
49  * @return True, if all result are valid
50  */
51  static bool testAveraging1Channel32Bit2x2(const double testDuration);
52 
53  /*
54  * Tests the SSE averaging functions for 2 channel 16 bit.
55  * @param testDuration Number of seconds for each test, with range (0, infinity)
56  * @return True, if all result are valid
57  */
58  static bool testAveraging2Channel16Bit2x2(const double testDuration);
59 
60  /*
61  * Tests the SSE averaging functions for 2 channel 66 bit.
62  * @param testDuration Number of seconds for each test, with range (0, infinity)
63  * @return True, if all result are valid
64  */
65  static bool testAveraging2Channel64Bit2x2(const double testDuration);
66 
67  /*
68  * Tests the SSE averaging functions for 3 channel 24 bit.
69  * @param testDuration Number of seconds for each test, with range (0, infinity)
70  * @return True, if all result are valid
71  */
72  static bool testAveraging3Channel24Bit2x2(const double testDuration);
73 
74  /*
75  * Tests the SSE averaging functions for 3 channel 96 bit.
76  * @param testDuration Number of seconds for each test, with range (0, infinity)
77  * @return True, if all result are valid
78  */
79  static bool testAveraging3Channel96Bit2x2(const double testDuration);
80 
81  /*
82  * Tests the SSE averaging functions for 4 channel 32 bit.
83  * @param testDuration Number of seconds for each test, with range (0, infinity)
84  * @return True, if all result are valid
85  */
86  static bool testAveraging4Channel32Bit2x2(const double testDuration);
87 
88  /*
89  * Tests the SSE averaging functions for 4 channel 32 bit.
90  * @param testDuration Number of seconds for each test, with range (0, infinity)
91  * @return True, if all result are valid
92  */
93  static bool testAveraging4Channel128Bit2x2(const double testDuration);
94 
95  /*
96  * Tests the binary SSE averaging functions for 1 channel 8 bit.
97  * @param testDuration Number of seconds for each test, with range (0, infinity)
98  * @return True, if all result are valid
99  */
100  static bool testBinaryAveraging1Channel8Bit2x2(const double testDuration);
101 
102  /*
103  * Tests the SSE averaging functions for 1 channel 8 bit.
104  * @param testDuration Number of seconds for each test, with range (0, infinity)
105  * @return True, if all result are valid
106  */
107  static bool testAveraging1Channel8Bit3x3(const double testDuration);
108 
109  /**
110  * De-interleave test for 8 bit 3 channels data with 15 elements.
111  * @param testDuration Number of seconds for each test, with range (0, infinity)
112  * @return True, if succeeded
113  */
114  static bool testDeInterleave3Channel8Bit15Elements(const double testDuration);
115 
116  /**
117  * De-interleave test for 8 bit 3 channels data with 24 elements.
118  * @param testDuration Number of seconds for each test, with range (0, infinity)
119  * @return True, if succeeded
120  */
121  static bool testDeInterleave3Channel8Bit24Elements(const double testDuration);
122 
123  /**
124  * De-interleave test for 8 bit 3 channels data with 48 elements.
125  * @param testDuration Number of seconds for each test, with range (0, infinity)
126  * @return True, if succeeded
127  */
128  static bool testDeInterleave3Channel8Bit48Elements(const double testDuration);
129 
130  /**
131  * De-interleave test for 8 bit 3 channels data with 45 elements.
132  * @param testDuration Number of seconds for each test, with range (0, infinity)
133  * @return True, if succeeded
134  */
135  static bool testDeInterleave3Channel8Bit45Elements(const double testDuration);
136 
137  /**
138  * Interleave test for 8 bit 3 channels data with 48 elements.
139  * @param testDuration Number of seconds for each test, with range (0, infinity)
140  * @return True, if succeeded
141  */
142  static bool testInterleave3Channel8Bit48Elements(const double testDuration);
143 
144  /**
145  * Reverse channel order test for 8 bit 2 channels data with 32 elements.
146  * @param testDuration Number of seconds for each test, with range (0, infinity)
147  * @return True, if succeeded
148  */
149  static bool testReverseChannelOrder2Channel8Bit32Elements(const double testDuration);
150 
151  /**
152  * Reverse channel order test for 8 bit 3 channels data with 48 elements.
153  * @param testDuration Number of seconds for each test, with range (0, infinity)
154  * @return True, if succeeded
155  */
156  static bool testReverseChannelOrder3Channel8Bit48Elements(const double testDuration);
157 
158  /**
159  * Reverse channel order test for 8 bit 4 channels data with 64 elements.
160  * @param testDuration Number of seconds for each test, with range (0, infinity)
161  * @return True, if succeeded
162  */
163  static bool testReverseChannelOrder4Channel8Bit64Elements(const double testDuration);
164 
165  /**
166  * Reverse channel order and swap test for 8 bit 3 channels data with 48 elements.
167  * @return True, if succeeded
168  */
170 
171  /**
172  * Reverse element order test for 48 elements with 8 bit per element.
173  * @return True, if succeeded
174  */
176 
177  /**
178  * Reverse element order and swap test for 48 elements with 8 bit per element.
179  * @return True, if succeeded
180  */
182 
183  /**
184  * Sum of 1x16 elements of an interleaved image with 1 channels and 8 bit per channel.
185  * @return True, if succeeded
186  */
188 
189  /**
190  * Sum of 1x15 elements of an interleaved image with 1 channels and 8 bit per channel.
191  * @param testDuration Number of seconds for each test, with range (0, infinity)
192  * @return True, if succeeded
193  */
194  static bool testSumInterleave1Channel8Bit15Elements(const double testDuration);
195 
196  /**
197  * Sum of 3x16 elements of an interleaved image with 3 channels and 8 bit per channel.
198  * @return True, if succeeded
199  */
201 
202  /**
203  * Sum of 3x15 elements of an interleaved image with 3 channels and 8 bit per channel.
204  * @return True, if succeeded
205  */
207 
208  /**
209  * Tests the interpolation function for 3 channels and 24 bit per pixel image data.
210  * @param testDuration Number of seconds for each test, with range (0, infinity)
211  * @return True, if succeeded
212  */
213  static bool testInterpolation1Channel8Bit15Elements(const double testDuration);
214 
215  /**
216  * Tests the interpolation function for 3 channels and 24 bit per pixel image data.
217  * @param testDuration Number of seconds for each test, with range (0, infinity)
218  * @return True, if succeeded
219  */
220  static bool testInterpolation3Channel24Bit12Elements(const double testDuration);
221 
222  /**
223  * Tests the function adding an offset for 16 bit signed integer right shifts to perform a division by 2.
224  * @param testDuration Number of seconds for each test, with range (0, infinity)
225  * @return True, if succeeded
226  */
227  static bool testAddOffsetBeforeRightShiftDivisionByTwoSigned16Bit(const double testDuration);
228 
229  /**
230  * Tests the function adding an offset for 16 bit signed integer right shifts to perform a division.
231  * @param testDuration Number of seconds for each test, with range (0, infinity)
232  * @return True, if succeeded
233  */
234  static bool testAddOffsetBeforeRightShiftDivisionSigned16Bit(const double testDuration);
235 
236  /**
237  * Tests the function adding an offset for 32 bit signed integer right shifts to perform a division by 2.
238  * @param testDuration Number of seconds for each test, with range (0, infinity)
239  * @return True, if succeeded
240  */
241  static bool testAddOffsetBeforeRightShiftDivisionByTwoSigned32Bit(const double testDuration);
242 
243  /**
244  * Tests the function adding an offset for 32 bit signed integer right shifts to perform a division.
245  * @param testDuration Number of seconds for each test, with range (0, infinity)
246  * @return True, if succeeded
247  */
248  static bool testAddOffsetBeforeRightShiftDivisionSigned32Bit(const double testDuration);
249 
250  /**
251  * Tests the function multiplying eight 16 bit integer values.
252  * @param testDuration Number of seconds for each test, with range (0, infinity)
253  * @return True, if succeeded
254  */
255  static bool testMultiplyInt8x16ToInt32x8(const double testDuration);
256 
257  /**
258  * Tests the function multiplying and accumulating eight 16 bit integer values.
259  * @param testDuration Number of seconds for each test, with range (0, infinity)
260  * @return True, if succeeded
261  */
262  static bool testMultiplyInt8x16ToInt32x8AndAccumulate(const double testDuration);
263 
264  private:
265 
266  /**
267  * Average of 2x elements pixel of a gray scale image with 8 bit using SSE function.
268  * @param testDuration Number of seconds for each test, with range (0, infinity)
269  * @param elements element size of SSE function {8, 16, 32}
270  * @return True, if all result are valid
271  */
272  static bool testAverageElements1Channel8Bit2x2(const double testDuration, const unsigned int elements);
273 
274  /**
275  * Average of 2x elements pixel of a binary image with 8 bit using SSE function.
276  * @param testDuration Number of seconds for each test, with range (0, infinity)
277  * @param elements element size of SSE function {16}
278  * @param sumThreshold Minimal sum threshold of four pixels to result in a pixel with value 255
279  * @return True, if all result are valid
280  */
281  static bool testAverageElementsBinary1Channel8Bit2x2(const double testDuration, const unsigned int elements, const unsigned int sumThreshold = 640u);
282 
283  /**
284  * Average of 2x elements pixel of a gray scale image with 32 bit using SSE function.
285  * @param testDuration Number of seconds for each test, with range (0, infinity)
286  * @param elements element size of SSE function {8}
287  * @return True, if all result are valid
288  */
289  static bool testAverageElements1Channel32Bit2x2(const double testDuration, const unsigned int elements);
290 
291  /**
292  * Average of 3x elements pixel of a gray scale image with 8 bit using SSE function.
293  * @param testDuration Number of seconds for each test, with range (0, infinity)
294  * @param elements element size of SSE function {30}
295  * @return True, if all result are valid
296  */
297  static bool testAverageElements1Channel8Bit3x3(const double testDuration, const unsigned int elements);
298 
299  /**
300  * Average of 2x 'elements/2' pixel of a gray scale image with alpha channel and 8 bit per channel using SSE function.
301  * @param testDuration Number of seconds for each test, with range (0, infinity)
302  * @param elements element size of SSE function {8}
303  * @return True, if all result are valid
304  */
305  static bool testAverageElements2Channel16Bit2x2(const double testDuration, const unsigned int elements);
306 
307  /**
308  * Average of 2x 'elements/2' pixel of a gray scale image with alpha channel and 32 bit per channel using SSE function.
309  * @param testDuration Number of seconds for each test, with range (0, infinity)
310  * @param elements element size of SSE function {8, 16, 32}
311  * @return True, if all result are valid
312  */
313  static bool testAverageElements2Channel64Bit2x2(const double testDuration, const unsigned int elements);
314 
315  /**
316  * Average of 2x 'elements/3' pixel of a 3 channel image and 8 bit per channel using SSE function.
317  * @param testDuration Number of seconds for each test, with range (0, infinity)
318  * @param elements element size of SSE function {12, 24}
319  * @return True, if all result are valid
320  */
321  static bool testAverageElements3Channel24Bit2x2(const double testDuration, const unsigned int elements);
322 
323  /**
324  * Average of 2x 'elements/3' pixel of a 3 channel image and 32 bit per channel using SSE function.
325  * @param testDuration Number of seconds for each test, with range (0, infinity)
326  * @param elements element size of SSE function {6}
327  * @return True, if all result are valid
328  */
329  static bool testAverageElements3Channel96Bit2x2(const double testDuration, const unsigned int elements);
330 
331  /**
332  * Average of 2x 'elements/4' pixel of a 4 channel image and 8 bit per channel using SSE function.
333  * @param testDuration Number of seconds for each test, with range (0, infinity)
334  * @param elements element size of SSE function {16, 32}
335  * @return True, if all result are valid
336  */
337  static bool testAverageElements4Channel32Bit2x2(const double testDuration, const unsigned int elements);
338 
339  /**
340  * Average of 2x 'elements/4' pixel of a 4 channel image and 32 bit per channel using SSE function.
341  * @param testDuration Number of seconds for each test, with range (0, infinity)
342  * @param elements element size of SSE function {8}
343  * @return True, if all result are valid
344  */
345  static bool testAverageElements4Channel128Bit2x2(const double testDuration, const unsigned int elements);
346 
347  /**
348  * Average of 2x2 pixel block of a gray scale image with 8 bit.
349  * @param elements length of averageLine buffer
350  * @param imageLine0Buffer8Bit buffer of even gray image lines
351  * @param imageLine1Buffer8Bit buffer of odd gray image lines
352  * @param averageLine resulting average image line
353  * @return True, if succeeded
354  */
355  static bool referenceAverageElements1Channel8Bit2x2(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, uint8_t* const averageLine);
356 
357  /**
358  * Average of 2x2 pixel block of an binary image with 8 bit.
359  * @param elements length of averageLine buffer
360  * @param imageLine0Buffer8Bit buffer of even binary image lines
361  * @param imageLine1Buffer8Bit buffer of odd binary image lines
362  * @param averageLine resulting average image line
363  * @param sumThreshold Minimal sum threshold of four pixels to result in a pixel with value 255
364  * @return True, if succeeded
365  */
366  static bool referenceAverageElementsBinary1Channel8Bit2x2(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, uint8_t* const averageLine, const unsigned int sumThreshold = 766u);
367 
368  /**
369  * Average of 3x3 pixel block of a gray scale image with 8 bit.
370  * @param elements length of averageLine buffer
371  * @param imageLine0Buffer8Bit buffer of even gray image lines
372  * @param imageLine1Buffer8Bit buffer of odd gray image lines
373  * @param imageLine2Buffer8Bit buffer of odd gray image lines
374  * @param averageLine resulting average image line
375  * @return True, if succeeded
376  */
377  static bool referenceAverageElements1Channel8Bit3x3(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, const uint8_t* const imageLine2Buffer8Bit, uint8_t* const averageLine);
378 
379  /**
380  * Average of 2x2 pixel block of a gray scale image with 32 bit.
381  * @param elements length of averageLine buffer
382  * @param imageLine0Buffer32Bit buffer of even gray image lines
383  * @param imageLine1Buffer32Bit buffer of odd gray image lines
384  * @param averageLine resulting average image line
385  * @return True, if succeeded
386  */
387  static bool referenceAverageElements1Channel32Bit2x2(const unsigned int elements, const float* const imageLine0Buffer32Bit, const float* const imageLine1Buffer32Bit, float* const averageLine);
388 
389  /**
390  * Average of 2x2 pixel block of a gray scale image with alpha channel and 8 bit per channel.
391  * @param elements length of averageLine buffer
392  * @param imageLine0Buffer8Bit buffer of even image lines
393  * @param imageLine1Buffer8Bit buffer of odd image lines
394  * @param averageLine resulting average image line
395  * @return True, if succeeded
396  */
397  static bool referenceAverageElements2Channel16Bit2x2(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, uint8_t* const averageLine);
398 
399  /**
400  * Average of 2x2 pixel block of a gray scale image with alpha channel and 32 bit per channel.
401  * @param elements length of averageLine buffer
402  * @param imageLine0Buffer32Bit buffer of even image lines
403  * @param imageLine1Buffer32Bit buffer of odd image lines
404  * @param averageLine resulting average image line
405  * @return True, if succeeded
406  */
407  static bool referenceAverageElements2Channel64Bit2x2(const unsigned int elements, const float* const imageLine0Buffer32Bit, const float* const imageLine1Buffer32Bit, float* const averageLine);
408 
409  /**
410  * Average of 2x2 pixel block of an 3 channel image and 8 bit per channel.
411  * @param elements length of averageLine buffer
412  * @param imageLine0Buffer8Bit buffer of even image lines
413  * @param imageLine1Buffer8Bit buffer of odd image lines
414  * @param averageLine resulting average image line
415  * @return True, if succeeded
416  */
417  static bool referenceAverageElements3Channel24Bit2x2(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, uint8_t* const averageLine);
418 
419  /**
420  * Average of 2x2 pixel block of an 3 channel image and 32 bit per channel.
421  * @param elements length of averageLine buffer
422  * @param imageLine0Buffer32Bit buffer of even image lines
423  * @param imageLine1Buffer32Bit buffer of odd image lines
424  * @param averageLine resulting average image line
425  * @return True, if succeeded
426  */
427  static bool referenceAverageElements3Channel96Bit2x2(const unsigned int elements, const float* const imageLine0Buffer32Bit, const float* const imageLine1Buffer32Bit, float* const averageLine);
428 
429  /**
430  * Average of 2x2 pixel block of an 4 channel image and 8 bit per channel.
431  * @param elements length of averageLine buffer
432  * @param imageLine0Buffer8Bit buffer of even image lines
433  * @param imageLine1Buffer8Bit buffer of odd image lines
434  * @param averageLine resulting average image line
435  * @return True, if succeeded
436  */
437  static bool referenceAverageElements4Channel32Bit2x2(const unsigned int elements, const uint8_t* const imageLine0Buffer8Bit, const uint8_t* const imageLine1Buffer8Bit, uint8_t* const averageLine);
438 
439  /**
440  * Average of 2x2 pixel block of an 4 channel image and 32 bit per channel.
441  * @param elements length of averageLine buffer
442  * @param imageLine0Buffer32Bit buffer of even image lines
443  * @param imageLine1Buffer32Bit buffer of odd image lines
444  * @param averageLine resulting average image line
445  * @return True, if succeeded
446  */
447  static bool referenceAverageElements4Channel128Bit2x2(const unsigned int elements, const float* const imageLine0Buffer32Bit, const float* const imageLine1Buffer32Bit, float* const averageLine);
448 };
449 
450 }
451 
452 }
453 
454 }
455 
456 #endif // OCEAN_HARDWARE_SSE_VERSION >= 41
457 
458 #endif // META_OCEAN_TEST_TESTCV_TEST_SSE_H
This class implements a Computer Vision SSE test.
Definition: TestSSE.h:29
static bool testAverageElements4Channel32Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/4' pixel of a 4 channel image and 8 bit per channel using SSE function.
static bool testAverageElements1Channel32Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x elements pixel of a gray scale image with 32 bit using SSE function.
static bool testDeInterleave3Channel8Bit45Elements(const double testDuration)
De-interleave test for 8 bit 3 channels data with 45 elements.
static bool referenceAverageElements3Channel96Bit2x2(const unsigned int elements, const float *const imageLine0Buffer32Bit, const float *const imageLine1Buffer32Bit, float *const averageLine)
Average of 2x2 pixel block of an 3 channel image and 32 bit per channel.
static bool testAveraging1Channel8Bit2x2(const double testDuration)
static bool testAverageElementsBinary1Channel8Bit2x2(const double testDuration, const unsigned int elements, const unsigned int sumThreshold=640u)
Average of 2x elements pixel of a binary image with 8 bit using SSE function.
static bool testAveraging4Channel128Bit2x2(const double testDuration)
static bool referenceAverageElementsBinary1Channel8Bit2x2(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, uint8_t *const averageLine, const unsigned int sumThreshold=766u)
Average of 2x2 pixel block of an binary image with 8 bit.
static bool testAverageElements4Channel128Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/4' pixel of a 4 channel image and 32 bit per channel using SSE function.
static bool testSumInterleave3Channel8Bit45Elements()
Sum of 3x15 elements of an interleaved image with 3 channels and 8 bit per channel.
static bool referenceAverageElements2Channel64Bit2x2(const unsigned int elements, const float *const imageLine0Buffer32Bit, const float *const imageLine1Buffer32Bit, float *const averageLine)
Average of 2x2 pixel block of a gray scale image with alpha channel and 32 bit per channel.
static bool testAverageElements2Channel64Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/2' pixel of a gray scale image with alpha channel and 32 bit per channel usin...
static bool testInterpolation3Channel24Bit12Elements(const double testDuration)
Tests the interpolation function for 3 channels and 24 bit per pixel image data.
static bool testReverseChannelOrder2Channel8Bit32Elements(const double testDuration)
Reverse channel order test for 8 bit 2 channels data with 32 elements.
static bool referenceAverageElements1Channel8Bit3x3(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, const uint8_t *const imageLine2Buffer8Bit, uint8_t *const averageLine)
Average of 3x3 pixel block of a gray scale image with 8 bit.
static bool testDeInterleave3Channel8Bit48Elements(const double testDuration)
De-interleave test for 8 bit 3 channels data with 48 elements.
static bool testMultiplyInt8x16ToInt32x8(const double testDuration)
Tests the function multiplying eight 16 bit integer values.
static bool testAddOffsetBeforeRightShiftDivisionByTwoSigned32Bit(const double testDuration)
Tests the function adding an offset for 32 bit signed integer right shifts to perform a division by 2...
static bool testAveraging4Channel32Bit2x2(const double testDuration)
static bool testAddOffsetBeforeRightShiftDivisionSigned16Bit(const double testDuration)
Tests the function adding an offset for 16 bit signed integer right shifts to perform a division.
static bool testSumInterleave3Channel8Bit48Elements()
Sum of 3x16 elements of an interleaved image with 3 channels and 8 bit per channel.
static bool testSwapReversedElements8Bit48Elements()
Reverse element order and swap test for 48 elements with 8 bit per element.
static bool referenceAverageElements3Channel24Bit2x2(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, uint8_t *const averageLine)
Average of 2x2 pixel block of an 3 channel image and 8 bit per channel.
static bool testReverseChannelOrder4Channel8Bit64Elements(const double testDuration)
Reverse channel order test for 8 bit 4 channels data with 64 elements.
static bool testInterleave3Channel8Bit48Elements(const double testDuration)
Interleave test for 8 bit 3 channels data with 48 elements.
static bool referenceAverageElements1Channel8Bit2x2(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, uint8_t *const averageLine)
Average of 2x2 pixel block of a gray scale image with 8 bit.
static bool testDeInterleave3Channel8Bit15Elements(const double testDuration)
De-interleave test for 8 bit 3 channels data with 15 elements.
static bool testReverseElements8Bit48Elements()
Reverse element order test for 48 elements with 8 bit per element.
static bool testReverseChannelOrder3Channel8Bit48Elements(const double testDuration)
Reverse channel order test for 8 bit 3 channels data with 48 elements.
static bool testAveraging2Channel64Bit2x2(const double testDuration)
static bool referenceAverageElements1Channel32Bit2x2(const unsigned int elements, const float *const imageLine0Buffer32Bit, const float *const imageLine1Buffer32Bit, float *const averageLine)
Average of 2x2 pixel block of a gray scale image with 32 bit.
static bool testAveraging1Channel8Bit3x3(const double testDuration)
static bool testAverageElements1Channel8Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x elements pixel of a gray scale image with 8 bit using SSE function.
static bool testAveraging2Channel16Bit2x2(const double testDuration)
static bool testDeInterleave3Channel8Bit24Elements(const double testDuration)
De-interleave test for 8 bit 3 channels data with 24 elements.
static bool testAverageElements1Channel8Bit3x3(const double testDuration, const unsigned int elements)
Average of 3x elements pixel of a gray scale image with 8 bit using SSE function.
static bool testSumInterleave1Channel8Bit16Elements()
Sum of 1x16 elements of an interleaved image with 1 channels and 8 bit per channel.
static bool testSwapReversedChannelOrder3Channel8Bit48Elements()
Reverse channel order and swap test for 8 bit 3 channels data with 48 elements.
static bool testAveraging3Channel24Bit2x2(const double testDuration)
static bool testAverageElements2Channel16Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/2' pixel of a gray scale image with alpha channel and 8 bit per channel using...
static bool testAveraging3Channel96Bit2x2(const double testDuration)
static bool testAverageElements3Channel96Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/3' pixel of a 3 channel image and 32 bit per channel using SSE function.
static bool testAveraging1Channel32Bit2x2(const double testDuration)
static bool referenceAverageElements4Channel32Bit2x2(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, uint8_t *const averageLine)
Average of 2x2 pixel block of an 4 channel image and 8 bit per channel.
static bool testAverageElements3Channel24Bit2x2(const double testDuration, const unsigned int elements)
Average of 2x 'elements/3' pixel of a 3 channel image and 8 bit per channel using SSE function.
static bool testAddOffsetBeforeRightShiftDivisionSigned32Bit(const double testDuration)
Tests the function adding an offset for 32 bit signed integer right shifts to perform a division.
static bool referenceAverageElements4Channel128Bit2x2(const unsigned int elements, const float *const imageLine0Buffer32Bit, const float *const imageLine1Buffer32Bit, float *const averageLine)
Average of 2x2 pixel block of an 4 channel image and 32 bit per channel.
static bool referenceAverageElements2Channel16Bit2x2(const unsigned int elements, const uint8_t *const imageLine0Buffer8Bit, const uint8_t *const imageLine1Buffer8Bit, uint8_t *const averageLine)
Average of 2x2 pixel block of a gray scale image with alpha channel and 8 bit per channel.
static bool test(const double testDuration)
Tests the entire SSE class.
static bool testMultiplyInt8x16ToInt32x8AndAccumulate(const double testDuration)
Tests the function multiplying and accumulating eight 16 bit integer values.
static bool testSumInterleave1Channel8Bit15Elements(const double testDuration)
Sum of 1x15 elements of an interleaved image with 1 channels and 8 bit per channel.
static bool testAddOffsetBeforeRightShiftDivisionByTwoSigned16Bit(const double testDuration)
Tests the function adding an offset for 16 bit signed integer right shifts to perform a division by 2...
static bool testInterpolation1Channel8Bit15Elements(const double testDuration)
Tests the interpolation function for 3 channels and 24 bit per pixel image data.
static bool testBinaryAveraging1Channel8Bit2x2(const double testDuration)
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15