OSVR-Core
|
Header. More...
#include "BodyIdTypes.h"
#include <osvr/Util/TypeSafeId.h>
#include <boost/assert.hpp>
#include <stdexcept>
Go to the source code of this file.
Classes | |
struct | osvr::util::typesafeid_traits::WrappedType< vbtracker::detail::ZeroBasedBeaconIdTag > |
Tag-based specialization of underlying value type for beacon ID. More... | |
struct | osvr::util::typesafeid_traits::WrappedType< vbtracker::detail::OneBasedBeaconIdTag > |
Tag-based specialization of underlying value type for beacon ID. More... | |
Namespaces | |
osvr | |
The main namespace for all C++ elements of the framework, internal and external. | |
osvr::util | |
The Util library: Functionality not necessarily coupled to any particular core library, serving more as a common base layer behind all systems. | |
osvr::util::typesafeid_traits | |
Namespace for traits templates associated with osvr::util::TypeSafeId. | |
Typedefs | |
using | osvr::vbtracker::UnderlyingBeaconIdType = int |
All beacon IDs, whether 0 or 1 based, are ints on the inside. | |
using | osvr::vbtracker::ZeroBasedBeaconId = util::TypeSafeId< detail::ZeroBasedBeaconIdTag > |
Type-safe zero-based beacon ID. | |
using | osvr::vbtracker::OneBasedBeaconId = util::TypeSafeId< detail::OneBasedBeaconIdTag > |
Type-safe one-based beacon ID. | |
Functions | |
OneBasedBeaconId | osvr::vbtracker::makeOneBased (ZeroBasedBeaconId id) |
Overloaded conversion function to turn any beacon ID into one-based, respecting the convention that negative values don't change. More... | |
OneBasedBeaconId const & | osvr::vbtracker::makeOneBased (OneBasedBeaconId const &id) |
No-op overload, so you can take any beacon ID and ensure it is one-based. More... | |
ZeroBasedBeaconId | osvr::vbtracker::makeZeroBased (OneBasedBeaconId id) |
Overloaded conversion function to turn any beacon ID into zero-based, respecting the convention that negative values don't change. More... | |
ZeroBasedBeaconId const & | osvr::vbtracker::makeZeroBased (ZeroBasedBeaconId const &id) |
No-op overload, so you can take any beacon ID and ensure it is zero-based. More... | |
bool | osvr::vbtracker::beaconIdentified (ZeroBasedBeaconId id) |
Does the given beacon ID indicate that it's identified? | |
std::size_t | osvr::vbtracker::asIndex (ZeroBasedBeaconId id) |
Turn a (valid non-sentinel, i.e. More... | |
Header.
|
inline |
Turn a (valid non-sentinel, i.e.
identified) beacon id into an array index.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
inline |
Overloaded conversion function to turn any beacon ID into one-based, respecting the convention that negative values don't change.
|
inline |
No-op overload, so you can take any beacon ID and ensure it is one-based.
|
inline |
Overloaded conversion function to turn any beacon ID into zero-based, respecting the convention that negative values don't change.
|
inline |
No-op overload, so you can take any beacon ID and ensure it is zero-based.