Skip to content

Commit c955710

Browse files
committed
OpenVR SDK 0.9.15
General: * Several event members have been changes from enum values to plain-old-data types to guarantee compatibility across compiler vendors. IVRSystem: * PollNextEvent() and PollNextEventWithPose() now take a parameter for the size in bytes of the VREvent object you are passing in * The data member in VREvent_t is now variable length and at the end of the structure. IVRApplications: * Added VRApplicationProperty_LastLaunchTime_Uint64, which returns the last launch time for an application in seconds since January 1, 1970. IVRCompositor: * Compositor_FrameTiming is totally different. What should we tell people, Aaron? IVROverlay: * Added the ability to render an overlay wrapped around a component on a tracked controller when in the dashboard or compositor. * k_EGamepadTextInputModeSubmit added for chat-style use of the keyboard where instead of a "Done" button there is a "Submit" button and it doesn't make the keyboard go away. * PollNextOverlayEvent() now takes a parameter for the size in bytes of the VREvent object you are passing in * For overlay applications there are now two new event types you can listen to, VREvent_Scroll and VREvent_TouchPadMove. These events are generated if the VROverlayFlags_SendVRScrollEvents or VROverlayFlags_SendVRTouchpadEvents flag is set on your overlay window. IVRRenderModels: * Added RenderModelHasComponent, which returns true if the named model has the named component. [git-p4: depot-paths = "//vr/steamvr/sdk_release/": change = 3265813]
1 parent 80f2e46 commit c955710

23 files changed

+539
-352
lines changed

bin/linux32/libopenvr_api.so

82.9 KB
Binary file not shown.

bin/linux32/libopenvr_api.so.dbg

620 KB
Binary file not shown.

bin/linux64/libopenvr_api.so

85.5 KB
Binary file not shown.

bin/linux64/libopenvr_api.so.dbg

812 KB
Binary file not shown.

bin/osx32/libopenvr_api.dylib

46.3 KB
Binary file not shown.
Binary file not shown.

bin/win32/openvr_api.dll

72 KB
Binary file not shown.

bin/win32/openvr_api.pdb

544 KB
Binary file not shown.

bin/win64/openvr_api.dll

86 KB
Binary file not shown.

bin/win64/openvr_api.pdb

472 KB
Binary file not shown.

headers/openvr.h

+130-186
Large diffs are not rendered by default.

headers/openvr_api.cs

+159-72
Large diffs are not rendered by default.

headers/openvr_api.json

+139-50
Large diffs are not rendered by default.

headers/openvr_capi.h

+54-30
Large diffs are not rendered by default.

headers/openvr_driver.h

+54-11
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,7 @@ enum ETrackedDeviceProperty
223223
Prop_ContainsProximitySensor_Bool = 1025,
224224
Prop_DeviceProvidesBatteryStatus_Bool = 1026,
225225
Prop_DeviceCanPowerOff_Bool = 1027,
226+
Prop_Firmware_ProgrammingTarget_String = 1028,
226227

227228
// Properties that are unique to TrackedDeviceClass_HMD
228229
Prop_ReportsTimeSinceVSync_Bool = 2000,
@@ -231,7 +232,7 @@ enum ETrackedDeviceProperty
231232
Prop_UserIpdMeters_Float = 2003,
232233
Prop_CurrentUniverseId_Uint64 = 2004,
233234
Prop_PreviousUniverseId_Uint64 = 2005,
234-
Prop_DisplayFirmwareVersion_String = 2006,
235+
Prop_DisplayFirmwareVersion_Uint64 = 2006,
235236
Prop_IsOnDesktop_Bool = 2007,
236237
Prop_DisplayMCType_Int32 = 2008,
237238
Prop_DisplayMCOffset_Float = 2009,
@@ -253,6 +254,8 @@ enum ETrackedDeviceProperty
253254
Prop_LensCenterRightV_Float = 2025,
254255
Prop_UserHeadToEyeDepthMeters_Float = 2026,
255256
Prop_CameraFirmwareVersion_Uint64 = 2027,
257+
Prop_CameraFirmwareDescription_String = 2028,
258+
Prop_DisplayFPGAVersion_Uint64 = 2029,
256259

257260
// Properties that are unique to TrackedDeviceClass_Controller
258261
Prop_AttachedDeviceId_String = 3000,
@@ -270,6 +273,7 @@ enum ETrackedDeviceProperty
270273
Prop_FieldOfViewBottomDegrees_Float = 4003,
271274
Prop_TrackingRangeMinimumMeters_Float = 4004,
272275
Prop_TrackingRangeMaximumMeters_Float = 4005,
276+
Prop_ModeLabel_String = 4006,
273277

274278
// Vendors are free to expose private debug data in this reserved region
275279
Prop_VendorSpecific_Reserved_Start = 10000,
@@ -355,6 +359,8 @@ enum EVREventType
355359
VREvent_MouseButtonUp = 302, // data is mouse
356360
VREvent_FocusEnter = 303, // data is overlay
357361
VREvent_FocusLeave = 304, // data is overlay
362+
VREvent_Scroll = 305, // data is mouse
363+
VREvent_TouchPadMove = 306, // data is mouse
358364

359365
VREvent_InputFocusCaptured = 400, // data is process
360366
VREvent_InputFocusReleased = 401, // data is process
@@ -469,7 +475,7 @@ inline uint64_t ButtonMaskFromId( EVRButtonId id ) { return 1ull << id; }
469475
/** used for controller button events */
470476
struct VREvent_Controller_t
471477
{
472-
EVRButtonId button;
478+
uint32_t button; // EVRButtonId enum
473479
};
474480

475481

@@ -485,8 +491,35 @@ enum EVRMouseButton
485491
/** used for simulated mouse events in overlay space */
486492
struct VREvent_Mouse_t
487493
{
488-
float x, y;
489-
EVRMouseButton button;
494+
float x, y; // co-ords are in GL space, bottom left of the texture is 0,0
495+
uint32_t button; // EVRMouseButton enum
496+
};
497+
498+
/** used for simulated mouse wheel scroll in overlay space */
499+
struct VREvent_Scroll_t
500+
{
501+
float xdelta, ydelta; // movement in fraction of the pad traversed since last delta, 1.0 for a full swipe
502+
uint32_t repeatCount;
503+
};
504+
505+
/** when in mouse input mode you can receive data from the touchpad, these events are only sent if the users finger
506+
is on the touchpad (or just released from it)
507+
**/
508+
struct VREvent_TouchPadMove_t
509+
{
510+
// true if the users finger is detected on the touch pad
511+
bool bFingerDown;
512+
513+
// How long the finger has been down in seconds
514+
float flSecondsFingerDown;
515+
516+
// These values indicate the starting finger position (so you can do some basic swipe stuff)
517+
float fValueXFirst;
518+
float fValueYFirst;
519+
520+
// This is the raw sampled coordinate without deadzoning
521+
float fValueXRaw;
522+
float fValueYRaw;
490523
};
491524

492525
/** notification related events. Details will still change at this point */
@@ -496,7 +529,6 @@ struct VREvent_Notification_t
496529
uint32_t notificationId;
497530
};
498531

499-
500532
/** Used for events about processes */
501533
struct VREvent_Process_t
502534
{
@@ -516,7 +548,7 @@ struct VREvent_Overlay_t
516548
/** Used for a few events about overlays */
517549
struct VREvent_Status_t
518550
{
519-
EVRState statusState;
551+
uint32_t statusState; // EVRState enum
520552
};
521553

522554
/** Used for keyboard events **/
@@ -537,8 +569,7 @@ struct VREvent_Chaperone_t
537569
uint64_t m_nCurrentUniverse;
538570
};
539571

540-
/** Not actually used for any events. It is just used to reserve
541-
* space in the union for future event types */
572+
/** Not actually used for any events */
542573
struct VREvent_Reserved_t
543574
{
544575
uint64_t reserved0;
@@ -556,6 +587,7 @@ typedef union
556587
VREvent_Reserved_t reserved;
557588
VREvent_Controller_t controller;
558589
VREvent_Mouse_t mouse;
590+
VREvent_Scroll_t scroll;
559591
VREvent_Process_t process;
560592
VREvent_Notification_t notification;
561593
VREvent_Overlay_t overlay;
@@ -564,15 +596,17 @@ typedef union
564596
VREvent_Ipd_t ipd;
565597
VREvent_Chaperone_t chaperone;
566598
VREvent_PerformanceTest_t performanceTest;
599+
VREvent_TouchPadMove_t touchPadMove;
567600
} VREvent_Data_t;
568601

569602
/** An event posted by the server to all running applications */
570603
struct VREvent_t
571604
{
572-
EVREventType eventType;
605+
uint32_t eventType; // EVREventType enum
573606
TrackedDeviceIndex_t trackedDeviceIndex;
574-
VREvent_Data_t data;
575607
float eventAgeSeconds;
608+
// event data must be the end of the struct as its size is variable
609+
VREvent_Data_t data;
576610
};
577611

578612

@@ -779,7 +813,6 @@ enum EVRInitError
779813

780814
VRInitError_VendorSpecific_UnableToConnectToOculusRuntime = 1000,
781815

782-
VRInitError_VendorSpecific_HmdFound_But = 1100,
783816
VRInitError_VendorSpecific_HmdFound_CantOpenDevice = 1101,
784817
VRInitError_VendorSpecific_HmdFound_UnableToRequestConfigStart = 1102,
785818
VRInitError_VendorSpecific_HmdFound_NoStoredConfig = 1103,
@@ -993,11 +1026,21 @@ namespace vr
9931026
static const char * const k_pch_Null_SecondsFromVsyncToPhotons_Float = "secondsFromVsyncToPhotons";
9941027
static const char * const k_pch_Null_DisplayFrequency_Float = "displayFrequency";
9951028

1029+
//-----------------------------------------------------------------------------
1030+
// user interface keys
1031+
static const char * const k_pch_UserInterface_Section = "userinterface";
1032+
static const char * const k_pch_UserInterface_StatusAlwaysOnTop_Bool = "StatusAlwaysOnTop";
1033+
9961034
//-----------------------------------------------------------------------------
9971035
// notification keys
9981036
static const char * const k_pch_Notifications_Section = "notifications";
9991037
static const char * const k_pch_Notifications_DoNotDisturb_Bool = "DoNotDisturb";
10001038

1039+
//-----------------------------------------------------------------------------
1040+
// keyboard keys
1041+
static const char * const k_pch_Keyboard_Section = "keyboard";
1042+
static const char * const k_pch_Keyboard_TutorialCompletions = "TutorialCompletions";
1043+
10011044
//-----------------------------------------------------------------------------
10021045
// perf keys
10031046
static const char * const k_pch_Perf_Section = "perfcheck";

lib/linux32/libopenvr_api.so

620 KB
Binary file not shown.

lib/linux64/libopenvr_api.so

812 KB
Binary file not shown.

lib/win32/openvr_api.lib

1.98 KB
Binary file not shown.

lib/win64/openvr_api.lib

1.96 KB
Binary file not shown.

samples/bin/win32/openvr_api.dll

72 KB
Binary file not shown.

samples/bin/win64/openvr_api.dll

86 KB
Binary file not shown.

samples/hellovr_opengl/hellovr_opengl_main.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -595,7 +595,7 @@ bool CMainApplication::HandleInput()
595595

596596
// Process SteamVR events
597597
vr::VREvent_t event;
598-
while( m_pHMD->PollNextEvent( &event ) )
598+
while( m_pHMD->PollNextEvent( &event, sizeof( event ) ) )
599599
{
600600
ProcessVREvent( event );
601601
}

samples/helloworldoverlay/openvroverlaycontroller.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ void COpenVROverlayController::OnTimeoutPumpEvents()
221221
}
222222

223223
vr::VREvent_t vrEvent;
224-
while( vr::VROverlay()->PollNextOverlayEvent( m_ulOverlayHandle, &vrEvent ) )
224+
while( vr::VROverlay()->PollNextOverlayEvent( m_ulOverlayHandle, &vrEvent, sizeof( vrEvent ) ) )
225225
{
226226
switch( vrEvent.eventType )
227227
{
@@ -313,7 +313,7 @@ void COpenVROverlayController::OnTimeoutPumpEvents()
313313

314314
if( m_ulOverlayThumbnailHandle != vr::k_ulOverlayHandleInvalid )
315315
{
316-
while( vr::VROverlay()->PollNextOverlayEvent( m_ulOverlayThumbnailHandle, &vrEvent ) )
316+
while( vr::VROverlay()->PollNextOverlayEvent( m_ulOverlayThumbnailHandle, &vrEvent, sizeof( vrEvent) ) )
317317
{
318318
switch( vrEvent.eventType )
319319
{

0 commit comments

Comments
 (0)