how to use the interface IVRSystem::ApplyTransform?
In general, the viewpoint position is the position of the helmet relative to the origin. Now I want to change the viewpoint position to the helmet relative to a coordinate (x, y, z), how can i achieve it? Whether through this interface ApplyTransform can be achieved?if so,How does the third parameter be initialized?
IVRSystem.ApplyTransform is used to take the pose result from GetControllerStateWithPose and transform it to a new location. This is useful for throwing mechanics. The value returned by GetControllerStateWithPose is based on the "zero" point of the controller which might not be the location you are interested in. This function accounts for rotational motion as it applies to tangential velocity.
I think what you are asking is about the coordinate space of the poses returned by WaitGetPoses/GetLastPoses. This can be controlled by settings IVRCompositor.SetTrackingSpace.
https://github.com/ValveSoftware/openvr/blob/master/headers/openvr.h#L2207
This defaults to standing, where 0,0,0 represents the center of the user configured play area (on the floor).
You can change this to seated where 0,0,0 represents the center of the headset as configured by the user.
You can apply this to a world space transform used to represent how the player's play area maps to your simulation world.