Contents

SCNCamera

A set of camera attributes that can be attached to a node to provide a point of view for displaying the scene.

Declaration

class SCNCamera

Overview

To display a scene, you must designate a node whose camera property contains a camera object as the point of view.

The SCNNode object containing a camera defines a point of view—that is, the position and orientation of the camera. A camera’s direction of view is always along the negative z-axis of the node’s local coordinate system. To point the camera at different parts of your scene, use the position, rotation, or transform property of the node containing it. (Alternatively, to ensure that a camera always points at a particular element of your scene even when that element moves, attach a SCNLookAtConstraint object to the node containing the camera.)

An SCNCamera object itself defines the shape and, in part, the appearance of the rendered scene as seen from its point of view. By default, a camera defines a perspective projection, whose field of view (FOV) and near and far visibility limits you control using the properties listed in Adjusting Camera Perspective and illustrated below.

[Image]

Topics

Managing Camera Attributes

Adjusting Camera Perspective

Managing Field of View

Managing the Projection Transform

Choosing Nodes to Be Visible to the Camera

Adding Depth-of-Field Effects

Adding Motion Blur Effects

Adding High Dynamic Range Effects

Adding Automatic HDR Exposure Adaptation

Adjusting Rendered Colors

Adding Stylistic Visual Effects

Adding Screen-Space Ambient Occlusion

Deprecated

Initializers

Instance Properties

Instance Methods

See Also

Lighting, Cameras, and Shading