#include "openvr/openvrsystem.h"
#endif
#ifdef WITH_LIBOVR
-#include "ovr/oculusriftsystem.h"
+#include "libovr/libovrsystem.h"
#endif
using namespace std;
#endif
#ifdef WITH_LIBOVR
if(type=="libovr")
- return new OculusRiftSystem;
+ return new LibOVRSystem;
#endif
throw invalid_argument(format("system '%s' not supported", type));
}
+System *System::create_autodetect()
+{
+#ifdef WITH_OPENVR
+ if(OpenVRSystem::is_maybe_available())
+ {
+ try
+ {
+ return new OpenVRSystem;
+ }
+ catch(const runtime_error &)
+ { }
+ }
+#endif
+
+#ifdef WITH_LIBOVR
+ try
+ {
+ return new LibOVRSystem;
+ }
+ catch(const runtime_error &)
+ { }
+#endif
+
+ return 0;
+}
+
+void System::set_absolute_tracking(bool a)
+{
+ if(a)
+ throw invalid_argument("absolute tracking not supported");
+}
+
+MotionController *System::create_controller()
+{
+ throw runtime_error("controller not supported");
+}
+
} // namespace VR
} // namespace Msp