Playmaker Forum

PlayMaker Feedback => Action Requests => Topic started by: Kubold on September 11, 2022, 07:14:29 AM

Title: Get XRDevice.refreshRate (or VRDevice.refreshRate) Action
Post by: Kubold on September 11, 2022, 07:14:29 AM
Hi,

I need to get the refresh rate of the user's HMD. I am using the older, built-in Oculus and OpenVR Unity functions ("XR Settings" in the Player tab).

Not sure which function to use, so maybe 2 Actions, one for each and I'll see which one works?

XRDevice.refreshRate:
https://docs.unity3d.com/2019.4/Documentation/ScriptReference/XR.XRDevice-refreshRate.html (https://docs.unity3d.com/2019.4/Documentation/ScriptReference/XR.XRDevice-refreshRate.html)

VRDevice.refreshRate:
https://docs.unity3d.com/2017.1/Documentation/ScriptReference/VR.VRDevice-refreshRate.html (https://docs.unity3d.com/2017.1/Documentation/ScriptReference/VR.VRDevice-refreshRate.html)

Thanks!
Title: Re: Get XRDevice.refreshRate (or VRDevice.refreshRate) Action
Post by: Kubold on October 03, 2022, 10:35:43 AM
I'll just bump it one time, but if it's not doable, that's ok. I tried to convert some other script so it does this, but of course, Unity just displays an error in my 'code'.