The available rendering options that you use to selectively disable
certain rendering effects.
RealityKit applies effects to the render make the AR experience more
immersive. You can selectively disable any of these effects by adding
one or more options from the ``ARView/RenderOptions-swift.struct`` set
to the view’s ``ARView/renderOptions-swift.property`` property.
When you initialize a new ``ARView`` instance, RealityKit automatically
disables certain effects for you, depending on the device hardware. You
can change the view’s ``ARView/renderOptions-swift.property`` to suit
your app’s needs, but be sure to consider your app’s GPU utilization
when doing so, as described in
<doc:improving-the-performance-of-a-realitykit-app>.
Members (12)
get · iOS 13.0+
disableHDR
TypeScript
get disableHDR(): Promise<ARView_RenderOptions>
Swift declaration
static let disableHDR: ARView.RenderOptions
Disable the high dynamic range post-processing effect.
RealityKit applies a high dynamic range effect, along with tone
mapping, as a post-processing step in the GPU during the render.
This effect is computationally inexpensive, but you can add the
``ARView/RenderOptions-swift.struct/disableHDR`` option to the
view’s ``ARView/renderOptions-swift.property`` set to turn the
effect off, if needed. Disabling the effect is most useful on older
devices, like those with an A9 processor or earlier.
When deciding whether to use any effect, be sure to consider your
app’s CPU and GPU utilization, as described in
<doc:improving-the-performance-of-a-realitykit-app>.
get · iOS 13.0+
disableFaceMesh
TypeScript
get disableFaceMesh(): Promise<ARView_RenderOptions>
Swift declaration
static let disableFaceMesh: ARView.RenderOptions
Disable generation of the face entity with the default occlusion material.
By default, <doc://com.apple.documentation/documentation/arkit> detects
people and hides virtual objects behind their faces.
get · iOS 13.0+
disableMotionBlur
TypeScript
get disableMotionBlur(): Promise<ARView_RenderOptions>
Swift declaration
static let disableMotionBlur: ARView.RenderOptions
Disable the motion blur for all virtual content.
A video stream consists of a sequence of images. Each image in the
sequence represents a short, but non-zero period of time.
Fast-moving, real-world objects captured within a frame can
experience a visual smearing, known as _motion blur_.
By default, virtual objects that appear in the scene don’t
experience motion blur. Instead, they exist at exactly one point in
the frame for any given image in the image sequence. RealityKit
offers an effect that introduces motion blur for virtual objects,
taking into account the relative motion of the camera and the
object.
Because of its computational cost, motion blur is off by default on
all but the latest hardware. To enable or disable the effect, you
add or remove the
``ARView/RenderOptions-swift.struct/disableMotionBlur`` option to or
from the ``ARView/renderOptions-swift.property`` set, respectively.
If you do enable motion blur, be sure to measure your app’s CPU and
GPU utilization to find out how it affects your app’s performance,
as described in <doc:improving-the-performance-of-a-realitykit-app>.
get · iOS 13.0+
disableCameraGrain
TypeScript
get disableCameraGrain(): Promise<ARView_RenderOptions>
Swift declaration
static let disableCameraGrain: ARView.RenderOptions
Disable the image noise effect.
Images from a camera may contain a small amount of noise, called
_camera grain_, that increases as the available light decreases.
Virtual objects rendered without noise and placed into an otherwise
grainy image look out of place. You can use RealityKit to add noise
to the rendered output to match noise in the camera feed.
| Without camera grain | With camera grain |
|:-:|:-:|
|  | 
Applying this effect involves a low, constant GPU cost. If
necessary, you can disable the effect by adding the
``ARView/RenderOptions-swift.struct/disableCameraGrain`` option to
the view’s ``ARView/renderOptions-swift.property`` set. Disabling
the effect is most useful for older devices, like those with an A9
processor or earlier.
When deciding whether to use any effect, be sure to consider your
app’s CPU and GPU utilization, as described in
<doc:improving-the-performance-of-a-realitykit-app>.
get · iOS 13.0+
disableDepthOfField
TypeScript
get disableDepthOfField(): Promise<ARView_RenderOptions>
Swift declaration
static let disableDepthOfField: ARView.RenderOptions
Disable the depth of field effect for all virtual content.
When you set the focal point of a camera, you actually choose a
range of focus rather than a point. Objects outside the range —
either too close or too far away — appear out of focus, while
objects inside the range appear in focus. The size of the range,
known as the depth of field, depends on characteristics of the lens,
the focal point, and other factors.

If you place a virtual object outside of the range of focus, it can
appear detached from the scene in which it appears unless you blur
the object to match its surroundings. In many cases, the depth of
field is large enough that this doesn’t matter. But if it does
matter for your app, you can enable a post-processing effect that
blurs virtual objects to account for depth of field.
| Without depth of field | With depth of field |
|:-:|:-:|
|  | 
Because of its computational cost, the system disables depth of
field by default when you create a new ``ARView`` instance. To
enable depth of field, remove the
``ARView/RenderOptions-swift.struct/disableDepthOfField`` option
from the ``ARView/renderOptions-swift.property`` set. If you do
enable depth of field, be sure to check your app’s performance, as
described in <doc:improving-the-performance-of-a-realitykit-app>.
get · iOS 13.0+ · Deprecated
disableFaceOcclusions
TypeScript
get disableFaceOcclusions(): Promise<ARView_RenderOptions>
Swift declaration
static let disableFaceOcclusions: ARView.RenderOptions
Disable automatic face occlusion.
By default, <doc://com.apple.documentation/documentation/arkit> detects
people and hides virtual objects behind their faces.
Add the ``ARView/RenderOptions-swift.struct/disableFaceOcclusions``
option to the AR view’s ``ARView/renderOptions-swift.property``
to disable this feature.
get · iOS 13.0+
disablePersonOcclusion
TypeScript
get disablePersonOcclusion(): Promise<ARView_RenderOptions>
Swift declaration
static let disablePersonOcclusion: ARView.RenderOptions
Disable person segmentation.
By default, ARKit detects users in the frame, and hides content
occluded by users. Add the
``ARView/RenderOptions-swift.struct/disablePersonOcclusion`` option
to the AR view’s ``ARView/renderOptions-swift.property`` to disable
this feature.
get · iOS 13.0+
disableGroundingShadows
TypeScript
get disableGroundingShadows(): Promise<ARView_RenderOptions>
Swift declaration
static let disableGroundingShadows: ARView.RenderOptions
Disable rendering of ambient occlusion and shadows that ground
objects in an AR scene.
Objects in the real world cast a grounding shadow onto adjacent
surfaces due to ambient light. This provides viewers with a visual
cue that the object is in close proximity to the surface. Objects
without a grounding shadow appear disconnected from their
environment. To create the same visual cue for virtual objects,
RealityKit provides a grounding shadow effect.

Applying this effect involves a low, constant GPU cost. You can
disable the effect by adding the
``ARView/RenderOptions-swift.struct/disableGroundingShadows`` option
to the view’s ``ARView/renderOptions-swift.property`` set, if
needed. Disabling the effect is most useful for older devices, like
those with an A9 processor or earlier.
get · iOS 13.0+ · Deprecated
disableAutomaticLighting
TypeScript
get disableAutomaticLighting(): Promise<ARView_RenderOptions>
Swift declaration
static let disableAutomaticLighting: ARView.RenderOptions
Disable automatic updates of the scene lighting.
By default, ARKit analyzes the scene lighting in captured camera
images and automatically updates lighting in the scene. Add the
``ARView/RenderOptions-swift.struct/disableAutomaticLighting``
option to the AR view’s ``ARView/renderOptions-swift.property`` to
disable the feature.
get · iOS 13.0+
disableAREnvironmentLighting
TypeScript
get disableAREnvironmentLighting(): Promise<ARView_RenderOptions>
Swift declaration
static let disableAREnvironmentLighting: ARView.RenderOptions
Disable lighting from environment probes.
By default, RealityKit automatically creates light probes to record
the lighting conditions both globally, and at appropriate points in
the scene. The framework adjusts the complexity of the light probe
set to match the capabilities of the GPU. For example, it might use
only a global probe on less capable devices. It then applies
environment lighting to virtual objects based on the probes.
To disable this effect, add this option to the ``ARView/renderOptions-swift.property`` set.
Alternatively, to use environment lighting but control the probes
manually, ensure the render option set doesn’t include this
option. Then configure the session for manual environment texturing,
using the
<doc://com.apple.documentation/documentation/arkit/arworldtrackingconfiguration/environmenttexturing/manual>
value.
For more information about creating and placing probes manually, see
<doc://com.apple.documentation/documentation/arkit/camera_lighting_and_effects/adding_realistic_reflections_to_an_ar_experience>.
Creates a new option set from the given raw value.
This initializer always succeeds, even if the value passed as `rawValue`
exceeds the static properties declared as part of the option set. This
example creates an instance of `ShippingOptions` with a raw value beyond
the highest element, with a bit mask that effectively contains all the
declared static members.
let extraOptions = ShippingOptions(rawValue: 255)
print(extraOptions.isStrictSuperset(of: .all))
// Prints "true"
- Parameter rawValue: The raw value of the option set to create. Each bit
of `rawValue` potentially represents an element of the option set,
though raw values may include bits that are not defined as distinct
values of the `OptionSet` type.
The corresponding value of the raw type.
A new instance initialized with `rawValue` will be equivalent to this
instance. For example:
enum PaperSize: String {
case A4, A5, Letter, Legal
}
let selectedSize = PaperSize.Letter
print(selectedSize.rawValue)
// Prints "Letter"
print(selectedSize == PaperSize(rawValue: selectedSize.rawValue)!)
// Prints "true"