Documentation update for VrApi — Oculus
Welcome to the Oculus Developer Forums!

Your participation on the forum is subject to the Oculus Code of Conduct.

In general, please be respectful and kind. If you violate the Oculus Code of Conduct, your access to the developer forums may be revoked at the discretion of Oculus staff.

Documentation update for VrApi

The documentation is out-of-date with respect to the API. This code sample...
ovrInputCapabilityHeader capsHeader;
if ( vrapi_EnumerateInputDevices( ovrContext, 0, &capsHeader ) >= 0 )
{
   if ( capsHeader.Type == ovrControllerType_TrackedRemote )
   {
      ovrInputTrackedRemoteCapabilities remoteCaps;
      if ( vrapi_GetInputDeviceCapabilities( ovr, &remoteCaps.Header ) >= 0 )
      {
            // remote is connected
      }
   }
}
...is missing the setting of the header specified in VrApi_Input.h before calling vrapi_GetInputDeviceCapabilities:
remoteCaps.Header = capsHeader;


Comments

  • rupertrupert Posts: 46
    Brain Burst
    While we're at it: I think ovrContext and ovr are both the same ovrMobile* and the variable names should be the same to avoid confusion.
Sign In or Register to comment.