Bitwise.h
Go to the documentation of this file.
1 
2 #pragma once
3 
4 #include "ionTypes.h"
5 
6 
7 namespace ion
8 {
9 
12  class Bitwise
13  {
14 
15  public:
16 
18  static uint BitsToByte(vector<uint> const & bits);
19 
22  static vector<uint> ByteToBits(uint const Byte);
23 
25  static uint BitCount(uint i);
26 
27  };
28 
29 }
static uint BitCount(uint i)
Counts the number of set bits.
Definition: Bitwise.cpp:33
Definition: CCatmullRomAdvancedSplineInterpolator.h:7
static vector< uint > ByteToBits(uint const Byte)
Extract the bits of a byte to a vector of 0 or 1 values Note that only the first 8 bits of Byte are e...
Definition: Bitwise.cpp:18
unsigned int uint
Definition: ionTypes.h:42
Defines typedefs for integer and floating point types.
static uint BitsToByte(vector< uint > const &bits)
Converts a vector of 0 or 1 bits to binary representation.
Definition: Bitwise.cpp:7
Tools for bitwise operations.
Definition: Bitwise.h:12