Header providing optimized integer byte-swap functionality through a single function template, implemented using platform special functions or intrinsics where possible. More...
#include <osvr/Util/StdInt.h>#include <osvr/Common/ConfigByteSwapping.h>#include <boost/integer.hpp>#include <type_traits>Go to the source code of this file.
Classes | |
| struct | osvr::common::detail::UnspecializedByteSwapBase |
| Tag type used only for recognizing ByteSwap specializations that aren't explicitly specialized. More... | |
| struct | osvr::common::detail::ByteSwap< T > |
| Template for providing/describing optimized/intrinsic byte swap functions. More... | |
| struct | osvr::common::detail::NoOpFunction |
| struct | osvr::common::detail::ByteSwap< uint8_t > |
| no-op swap for 1 byte. More... | |
| struct | osvr::common::detail::ByteSwap< int8_t > |
| no-op swap for 1 byte. More... | |
| struct | osvr::common::detail::IntegerByteSwapTraits< T > |
| Traits assisting selection of optimized integer byte swapping. More... | |
Namespaces | |
| osvr | |
| < | |
| osvr::common | |
| Handles spatial transformations. | |
Functions | |
| template<typename T > | |
| T | osvr::common::detail::genericByteSwap (T const v) |
| Universal byte-swap function that always works, but isn't necessarily optimized. | |
| template<typename T > | |
| T | osvr::common::detail::integerByteSwapImpl (T const v, typename std::enable_if< IntegerByteSwapTraits< T >::HAVE_BYTESWAPPER >::type *=nullptr) |
| Implementation of integerByteSwap(): Gets called when we have an exact match to an explicit specialization. | |
| template<typename T > | |
| T | osvr::common::detail::integerByteSwapImpl (T const v, typename std::enable_if< (!IntegerByteSwapTraits< T >::HAVE_BYTESWAPPER)&&(IntegerByteSwapTraits< T >::HAVE_OPPPOSITEBYTESWAPPER)>::type *=nullptr) |
| Implementation of integerByteSwap(): Gets called when we do not have an exact match to an explicit specialization, but we do have a match if we switch the signedness. | |
| template<typename T > | |
| T | osvr::common::detail::integerByteSwapImpl (T const v, typename std::enable_if< (!IntegerByteSwapTraits< T >::HAVE_BYTESWAPPER)&&(!IntegerByteSwapTraits< T >::HAVE_OPPPOSITEBYTESWAPPER)>::type *=nullptr) |
| Implementation of integerByteSwap(): Gets called if no explicit specialization exists (for the type or its opposite-signedness relative) | |
| template<typename Type > | |
| Type | osvr::common::integerByteSwap (Type const v) |
| Swap the order of bytes of an arbitrary integer type. | |
Header providing optimized integer byte-swap functionality through a single function template, implemented using platform special functions or intrinsics where possible.
Definition in file IntegerByteSwap.h.