public readonly record struct XrFieldOfViewThe four half-angles of an asymmetric view frustum, in radians.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
Four angles, not a field of view and an aspect ratio. A headset's frustum is not symmetric — the lenses are canted, so each eye sees further towards its own side than towards the nose — and a projection built from a single vertical FOV is wrong by several degrees in a way that shows up as the two eyes disagreeing about where things are.
The signs are OpenXR's and they are worth stating: left and down are negative, so the width of the frustum is tan(right) − tan(left) rather than a sum.
Fields and properties (5)
public float AngleLeftTo the left edge. Negative.
public float AngleRightTo the right edge. Positive.
public float AngleUpTo the top edge. Positive.
public float AngleDownTo the bottom edge. Negative.
public bool IsValidWhether it describes a frustum with any volume in it.
Methods (2)
public XrFieldOfView(float AngleLeft, float AngleRight, float AngleUp, float AngleDown)The four half-angles of an asymmetric view frustum, in radians.
public static XrFieldOfView Symmetric(float horizontal, float vertical)A symmetric frustum, for a null backend and for tests.
Used by (6)
- NullXrSessionVixen.Xr
- OpenXrSessionVixen.Xr.OpenXR
- XrCompositionViewVixen.Xr
- XrProjectionVixen.Xr
- XrProjectionTestsVixen.Xr.Tests
- XrViewVixen.Xr