lovr.headset.getViewAngles

Returns the view angles of one of the headset views.

These can be used with Mat4:fov to create a projection matrix.

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

left, right, top, bottom = lovr.headset.getViewAngles(view)

Arguments

NameTypeDescription
viewnumberThe view index.

Returns

NameTypeDescription
leftnumberThe left view angle, in radians.
rightnumberThe right view angle, in radians.
topnumberThe top view angle, in radians.
bottomnumberThe bottom view angle, in radians.

See also