Skip to content

@halone/sdk / eyeAspect

Function: eyeAspect() ​

ts
function eyeAspect(
   widthPx, 
   heightPx, 
   stereo
): number;

The shape of one eye's picture. A side-by-side frame much wider than 2:1 is full width per eye; anything narrower is the usual half-width kind, squeezed to be stretched back to the frame's own shape. Likewise for top-bottom. Kept in step with ImmersiveGeometry.eyeAspect in core-compositor.

Parameters ​

widthPx ​

number

heightPx ​

number

stereo ​

StereoLayout

Returns ​

number

Released under the MIT License.