lovr.headset.getViewPose

Returns the pose of one of the headset views. This info can be used to create view matrices or do other eye-dependent calculations.

If tracking data is unavailable for the view or the index is invalid, nil is returned.

x, y, z, angle, ax, ay, az = lovr.headset.getViewPose(view)

Arguments

NameTypeDescription
viewnumberThe view index.

Returns

NameTypeDescription
xnumberThe x coordinate of the view position, in meters.
ynumberThe y coordinate of the view position, in meters.
znumberThe z coordinate of the view position, in meters.
anglenumberThe amount of rotation around the rotation axis, in radians.
axnumberThe x component of the axis of rotation.
aynumberThe y component of the axis of rotation.
aznumberThe z component of the axis of rotation.

See also