#pragma once #include #include class ByteUtils { public: using Word = int; using DWord = int; static bool MSBIsOne(char c) { return c & (1 << 7); } static int GetWordFirstBit(const Word word) { return word & ByteUtils::WORD_FIRST_BIT; }; static int GetWordLastByte(const Word word) { return word & ByteUtils::WORD_LAST_BYTE; } static void ReverseBuffer(char* buffer, char* reverse, unsigned size, unsigned targetSize) { for(unsigned idx=0; idx