Skip to main content
API Reference SwiftyNsdk NsdkFrameData

CameraIntrinsics

Camera intrinsic parameters for geometric calibration....

Declaration

struct CameraIntrinsics

Summary

Camera intrinsic parameters for geometric calibration. This structure contains the internal geometric properties of the camera, including focal length, principal point, and resolution. These parameters are essential for accurate 3D reconstruction and AR tracking.


Constructors

Constructor

init(intrinsics: simd_float3x3, resolution: CGSize)

Summary

Creates camera intrinsics from a 3x3 intrinsic matrix and resolution.
- Parameters:
- intrinsics: The 3x3 camera intrinsic matrix
- resolution: Image resolution as CGSize


Overload

init(intrinsics: simd_float3x3, width: UInt32, height: UInt32)

Summary

Creates camera intrinsics from a 3x3 intrinsic matrix and dimensions.
The intrinsic matrix should be in the standard computer vision format:
<br />[fx 0 cx] <br />[ 0 fy cy] <br />[ 0 0 1] <br />
- Parameters:
- intrinsics: The 3x3 camera intrinsic matrix
- width: Image width in pixels
- height: Image height in pixels


Properties

NameTypeSummary
var focalLengthXFloat
Focal length in the X direction (in pixels).
This represents the camera's focal length scaled by the horizontal
pixel density. Used for projecting 3D points to 2D image coordinates.
var focalLengthYFloat
Focal length in the Y direction (in pixels).
This represents the camera's focal length scaled by the vertical
pixel density. May differ from focalLengthX if pixels are not square.
var principalPointXFloat
Principal point X coordinate (in pixels).
The X coordinate of the principal point, which is the intersection
of the optical axis with the image plane. Ideally at the image center.
var principalPointYFloat
Principal point Y coordinate (in pixels).
The Y coordinate of the principal point, which is the intersection
of the optical axis with the image plane. Ideally at the image center.
var resolutionXUInt32
Image width in pixels.
var resolutionYUInt32
Image height in pixels.

Operators

NameTypeSummary
static func != Bool
Returns a Boolean value indicating whether two values are not equal.
Inequality is the inverse of equality. For any values a and b, a != b
implies that a == b is false.
This is the default implementation of the not-equal-to operator (!=)
for any type that conforms to Equatable.
- Parameters:
- lhs: A value to compare.
- rhs: Another value to compare.

Relationships

conforms to: Swift.Equatable