FastLED 3.9.15
Loading...
Searching...
No Matches

◆ test_sub_sat_u8_16_full_clamp()

bool autoresearch::simd_check::test_sub_sat_u8_16_full_clamp ( )
inline

Definition at line 161 of file AutoResearchSimd.h.

161 {
162 // 0 - 255 = 0 (clamped), 255 - 0 = 255, equal values = 0
163 uint8_t a[16] = {0,255,100,0, 1,0,0,0, 0,255,100,0, 1,0,0,0};
164 uint8_t b[16] = {255,0,100,0, 0,1,255,128, 255,0,100,0, 0,1,255,128};
165 uint8_t expected[16] = {0,255,0,0, 1,0,0,0, 0,255,0,0, 1,0,0,0};
166 uint8_t output[16] = {0};
167 store_u8_16(output, sub_sat_u8_16(load_u8_16(a), load_u8_16(b)));
168 return compare_u8(expected, output, 16);
169}
bool compare_u8(const uint8_t *a, const uint8_t *b, size_t n)
unsigned char uint8_t
Definition s16x16x4.h:209

References compare_u8().

Referenced by getTests().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: