codex
|
Functions | |
template<unsigned char M> | |
constexpr auto | rmask (char c) |
Applies a mask and shifts right. | |
template<unsigned char M> | |
constexpr auto | lmask (char c) |
Shifts left and applies a mask. | |
template<unsigned char LM> | |
constexpr auto | merge (char c0, char c1) |
Merges parts of two bytes according to a mask. | |
template<auto max> | |
constexpr bool | check (auto ...vs) |
Checks that no value is equal to max , which must be a power of 2. | |
constexpr auto | lu (const auto &t, auto c) |
Looks up the value of byte c in look-up table t . | |
|
constexpr |
Checks that no value is equal to max
, which must be a power of 2.
|
constexpr |
Shifts left and applies a mask.
The input is shifted left by the amount of zero bits on the right side of the mask and the mask is applied.
|
constexpr |
Looks up the value of byte c
in look-up table t
.
|
constexpr |
Merges parts of two bytes according to a mask.
Applies lmask
to c0
and rmask
to c1
using LM
and its opposite and combines the result.
|
constexpr |
Applies a mask and shifts right.
The mask is applied to the input byte and the result is shifted right by the amount of zero bits on the right side of the mask.