示例#1
0
OVR_EXPORT ovrBool ovrHmd_SetBool(ovrHmd hmddesc, const char* propertyName, ovrBool value)
{
    OVR_ASSERT(hmddesc && propertyName);

    HMDState* hmds = (HMDState*)hmddesc->Handle;
    if (hmds)
    {
        return hmds->setBoolValue(propertyName, value != 0) ? 1 : 0;
    }
    return false;
}
示例#2
0
文件: OVR_CAPI.cpp 项目: DJoser/minko
OVR_EXPORT ovrBool ovrHmd_SetBool(ovrHmd hmddesc,
                                  const char* propertyName,
                                  ovrBool value)
{
    OVR_ASSERT(propertyName);
    if (hmddesc)
    {
        HMDState* hmds = (HMDState*)hmddesc->Handle;
        OVR_ASSERT(hmds);
        if (hmds)
        {
            return hmds->setBoolValue(propertyName, value != 0) ? 1 : 0;
        }
    }

    return NetClient::GetInstance()->SetBoolValue(InvalidVirtualHmdId, propertyName, (value != 0)) ? 1 : 0;
}