CameraRig class
Camera rig for VR: head position + rotation, with stereo eye offsets. Produces view and projection matrices for left/right eyes.
- Implemented types
Constructors
Properties
- far ↔ double
-
Far clip plane.
getter/setter pair
- fovY ↔ double
-
Field of view in radians (vertical).
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- headTransform → Transform3D
-
final
- ipd ↔ double
-
Inter-pupillary distance in meters (clamped between 50mm and 80mm).
getter/setter pair
- leftViewMatrix → Matrix4
-
View matrix for the left eye.
no setter
- monoViewMatrix → Matrix4
-
Monoscopic view matrix (center eye).
no setter
- near ↔ double
-
Near clip plane.
getter/setter pair
- pitch → double
-
Vertical elevation angle (radians).
no setter
- position ↔ Vector3
-
getter/setter pair
- rightViewMatrix → Matrix4
-
View matrix for the right eye.
no setter
- rotation ↔ Quaternion
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- yaw → double
-
Horizontal azimuth angle (radians).
no setter
Methods
-
faceTrackedProjectionMatrix(
{required Vector3 eyePosRelative, double screenWidth = 0.15, double screenHeight = 0.08}) → Matrix4 -
Generates a face-tracked holographic projection matrix.
eyePosRelativerepresents the user's tracked eye position relative to the screen center (in meters).screenWidthandscreenHeightrepresent the physical screen size of the phone. -
frustum(
double aspectRatio) → VrFrustum -
leftProjectionMatrix(
double aspectRatio) → Matrix4 - Off-axis stereo projection for left eye.
-
leftViewProjection(
double aspectRatio) → Matrix4 -
lookAt(
Vector3 target) → void -
monoViewProjection(
double aspectRatio) → Matrix4 -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
projectionMatrix(
double aspectRatio) → Matrix4 - Projection matrix for a given aspect ratio.
-
recenter(
) → void -
Recenters horizontal gaze heading (Yaw = 0°) while maintaining pitch (elevation).
override
-
reset(
) → void -
override
-
rightProjectionMatrix(
double aspectRatio) → Matrix4 - Off-axis stereo projection for right eye.
-
rightViewProjection(
double aspectRatio) → Matrix4 -
rotate(
double dYaw, double dPitch) → void -
override
-
setOrientation(
double yaw, double pitch) → void - Sets the absolute gaze angles in radians.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- comfortDistanceDefault → const double
- Default focal distance for spatial UI (1.8m).
- comfortDistanceMax → const double
- Maximum recommended distance for readable spatial UI (3.0m).
- comfortDistanceMin → const double
- Minimum recommended distance for UI/interactive elements (1.2m) to prevent VAC eye strain.
- defaultIpd → const double
- Default adult IPD in meters (64mm).
- maxIpd → const double
- Maximum recommended IPD in meters (80mm).
- minIpd → const double
- Minimum recommended IPD in meters (50mm).