Converting HID API to use be<> auto swapping type.

This commit is contained in:
Ben Vanik
2014-08-19 22:50:21 -07:00
parent 48a0e5c601
commit fb98683ed3
24 changed files with 325 additions and 518 deletions

View File

@@ -35,6 +35,8 @@ namespace poly {
#define POLY_BYTE_SWAP_64 __bswap_64
#endif // XE_COMPILER_MSVC
inline int8_t byte_swap(int8_t value) { return value; }
inline uint8_t byte_swap(uint8_t value) { return value; }
inline int16_t byte_swap(int16_t value) {
return static_cast<int16_t>(POLY_BYTE_SWAP_16(static_cast<int16_t>(value)));
}