-
-
Notifications
You must be signed in to change notification settings - Fork 33
dlib.core.bitio
Timur Gafarov edited this page Apr 26, 2017
·
1 revision
Bit-level manipulations.
-
T hiNibble(T)(T b)
- returns high nibble (half-byte) of a byteb
. -
T loNibble(T)(T b)
- returns low nibble (half-byte) of a byteb
. -
T swapEndian16(T)(T n)
- returns 16-bit integern
with swapped endianness. -
T setBit(T)(T b, uint pos, bool state)
- sets bit at positionpos
in integerb
tostate
. -
bool getBit(T)(T b, uint pos)
- returns bit at positionpos
in integerb
.