OSVR-Core  0.6-1962-g59773924
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
osvr::pluginkit Namespace Reference

Contains C++ header-only wrappers for the PluginKit C API.Use of these wrappers is optional: they duplicate functionality found in the C API as they are implemented in headers on top of the C API. However, they also provide a much cleaner, low-boilerplate interface for the most common operations. More...

Classes

class  DeviceToken
 Wrapper class for OSVR_DeviceToken. More...
 
class  ImagingInterface
 A class wrapping an imaging interface for a device. More...
 
class  ImagingMessage
 A class wrapping a cv::Mat representing a frame, as well as the sensor ID it corresponds to. Pass to osvr::pluginkit::DeviceToken::send() along with your osvr::pluginkit::ImagingInterface. More...
 
class  PluginContext
 C++ wrapper class for the opaque plugin context. More...
 

Functions

OSVR_MessageType registerMessageType (OSVR_PluginRegContext ctx, const char *name)
 Register or recall a message type by name. More...
 
OSVR_MessageType registerMessageType (OSVR_PluginRegContext ctx, std::string const &name)
 
template<typename T >
T * registerObjectForDeletion (OSVR_PluginRegContext ctx, T *obj)
 Registers an object to be destroyed with delete when the plugin is unloaded. More...
 
template<typename T >
void registerHardwareDetectCallback (OSVR_PluginRegContext ctx, T functor)
 Registers a function object to be called when the core requests a hardware detection. More...
 
template<typename T >
void registerDriverInstantiationCallback (OSVR_PluginRegContext ctx, const char driverName[], T functor)
 Registers a function object to be called when the server is told to instantiate a driver by name with parameters. More...
 

Detailed Description

Contains C++ header-only wrappers for the PluginKit C API.

Use of these wrappers is optional: they duplicate functionality found in the C API as they are implemented in headers on top of the C API. However, they also provide a much cleaner, low-boilerplate interface for the most common operations.

The free functions and the members of osvr::pluginkit::PluginContext perform the same functionality. Use of the class can just lead to cleaner code if your whole plugin is "C++-style".