HD Camera
Cameras capture and display your world to the user. Customize and manipulate your Cameras to present your Unity Project however you like. You can use an unlimited number of Cameras in a Scene and set them to render in any order, at any position on the screen.
The High Definition Render Pipeline (HDRP) includes an HD Camera that uses the HDAdditionalCameraData component. If you use a script to interact with the Camera, some properties that are inside the HDAdditionalCameraData component are displayed inside the Camera component.
Properties
The HDRP Camera shares many properties with the Standard Unity Camera.
General
Property | Description |
---|---|
Background Type | Use the drop-down to select the type of background that the Camera fills the screen with before it renders a frame. • Sky: The Camera fills the screen with the sky defined in the Visual Environment of the current Volume settings. • Color: The Camera fills the screen with the color set in Background Color. • None: The Camera does not clear the screen and shows what it rendered in the previous frame as the background instead. |
Background Color | Use the HDR color picker to select the color that the Camera uses to clear the screen before it renders a frame. The Camera uses this color if:You select Color from the Background Type drop-down.You select Sky from the Background Type drop-down and there is no valid sky for the Camera to use. |
Culling Mask | Use the drop-down to set the Layer Mask that the Camera uses to exclude GameObjects from the rendering process. The Camera only renders Layers that you include in the Layer Mask. |
Volume Layer Mask | Use the drop-down to set the Layer Mask that defines which Volumes affect this Camera. |
Volume Anchor Override | Assign a Transform that the Volume system uses to handle the position of this Camera. For example, if your application uses a third person view of a character, set this property to the character's Transform. The Camera then uses the post-processing and Scene settings for Volumes that the character enters.If you do not assign a Transform, the Camera uses its own Transform instead. |
Probe Layer Mask | Use the drop-down to set the Layer Mask that the Camera uses to exclude environment lights (light from Planar Reflection Probes and Reflection Probes). The Camera only uses Reflection Probes on Layers that you include in this Layer Mask. |
Occlusion Culling | Enable the checkbox to make this Camera not render GameObjects that are not currently visible. For more information, see the Occlusion Culling documentation. |
Projection | Use the drop-down to select the projection mode for the Camera. • Perspective: The Camera simulates perspective when it renders GameObjects. This means that GameObjects further from the Camera appear smaller than GameObjects that are closer. • Orthographic: The Camera renders GameObjects uniformly with no perspective. This means that GameObjects further from the Camera appear to be the same size as GameObjects that are closer. Currently, HDRP does not support this projection mode. If you select this projection mode, any HDRP feature that requires lighting does not work consistently. However, this projection mode does work consistently with Unlit Materials. |
FOV Axis | Use the drop-down to select the axis that you want the field of view to relate to. • Vertical: Allows you to set the Field of View using the vertical axis. • Horizontal: Allows you to set the Field of View using the horizontal axis.This property only appears when you select Perspective from the Projection drop-down. |
Field of View | Use the slider to set the viewing angle for the Camera, in degrees. This property only appears when you select Perspective from the Projection drop-down. |
Link FOV to Physical Camera | Enable the checkbox to make the Camera use its Physical Settings to calculate its viewing angle.This property only appears when you select Perspective from the Projection drop-down. |
Size | Set the size of the orthographic Camera. This property only appears when you select Orthographic from the Projection drop-down. |
Clipping Planes | Set the distances from the Camera at which Unity uses it to start and stop rendering GameObjects. • Near: The distance from the Camera at which Unity begins to use it to draw GameObjects. The Camera does not render anything that is closer to it than this distance. • Far: The distance from the Camera at which Unity ceases to use it to draw GameObjects. The Camera does not render anything that is further away from it than this distance. |
Anti-aliasing | Use the drop-down to select the method that this Camera uses for post-process anti-aliasing. A Camera can still use multisample anti-aliasing (MSAA), which is a hardware feature, at the same time as post-process anti-aliasing. To control post-process anti-aliasing, use the Frame Settings. • No Anti-aliasing: This Camera can process MSAA but does not process any post-process anti-aliasing. • Fast Approximate Anti-aliasing (FXAA): Smooths edges on a per-pixel level. This is the least resource intensive anti-aliasing technique in HDRP. • Temporal Anti-aliasing (TAA): Uses frames from a history buffer to smooth edges more effectively than fast approximate anti-aliasing. • Subpixel Morphological Anti-aliasing (SMAA): Finds patterns in borders of the image and blends the pixels on these borders according to the pattern. |
SMAA Quality Preset | Use the drop-down to select the quality of SMAA. The difference in resource intensity is fairly small between Low and High. • Low: The lowest SMAA quality. This is the least resource-intensive option. • Medium: A good balance between SMAA quality and resource intensity. • High: The highest SMAA quality. This is the most resource-intensive option.This property only appears when you select Subpixel Morphological Anti-aliasing (SMAA) from the Anti-aliasing drop-down. |
Dithering | Enable the checkbox to apply 8-bit dithering to the final render. This can help reduce banding on wide gradients and low light areas. |
Stop NaNs | Enable the checkbox to make this Camera replace values that are not a number (NaN) with a black pixel. This stops certain effects from breaking, but is a resource-intensive process. Only enable this feature if you experience NaN issues that you can not fix. |
Allow Dynamic Resolution | Enable the checkbox to make this Camera support dynamic resolution for buffers linked to it. |
Fullscreen Passthrough | Enable the checkbox to make this Camera skip rendering settings and directly render in full screen. This is useful for video. |
Custom Frame Settings | Enable the checkbox to override the default Frame Settings for this Camera. This exposes a new set of Frame Settings that you can use to change how this Camera renders the Scene. |
Physical Settings
Property | Description |
---|---|
Sensor Type | Use the drop-down to select the real-world camera format that you want the Camera to simulate. When you select a Camera Sensor Type, Unity automatically sets the Sensor Size to the correct values for that format. If you change the Sensor Size values manually, Unity automatically sets this property to Custom. |
Sensor Size | Set the size, in millimeters, of the real-world camera sensor. Unity sets the X and Y values automatically when you select the Sensor Type. You can enter custom values to fine-tune your sensor. |
ISO | Set the sensibility of the real-world camera sensor. Higher values increase the Camera's sensitivity to light and result in faster exposure times. This property affects Exposure if you set its Mode to Use Physical Camera. |
Shutter Speed | Set the exposure time for the camera. Lower values result in less exposed pictures. Use the drop-down to select the units for the exposure time. You can use Seconds or 1/Seconds. This property affects Exposure if you set its Mode to Use Physical Camera. |
Gate Fit | Use the drop-down to select the method that Unity uses to set the size of the resolution gate (aspect ratio of the device you run the application on) relative to the film gate (aspect ratio of the Physical Camera sensor). Vertical: Fits the resolution gate to the height of the film gate. If the sensor aspect ratio is larger than the device aspect ratio, Unity crops the rendered image at the sides. If the sensor aspect ratio is smaller than the device aspect ratio, Unity overscans the rendered image at the sides. If you select this method, changing the sensor width (Sensor Size > X property) has no effect on the rendered image. • Horizontal: Fits the resolution gate to the width of the film gate. If the sensor aspect ratio is larger than the device aspect ratio, Unity overscans the rendered image on the top and bottom. If the sensor aspect ratio is smaller than the device aspect ratio, Unity crops the rendered image on the top and bottom. If you select this method, changing the sensor height (Sensor Size > Y property) has no effect on the rendered image. • Fill: Fits the resolution gate to either the width or height of the film gate, whichever is smaller. This crops the rendered image. • Overscan: Fits the resolution gate to either the width or height of the film gate, whichever is larger. This overscans the rendered image. • None: Ignores the resolution gate and uses the film gate only. This stretches the rendered image to fit the device aspect ratio. |
Focal Length | Set the distance, in millimeters, between the Camera sensor and the Camera lens. Lower values result in a wider Field of View, and vice versa. This property affects Depth of Field if you set its Focus Mode to Use Physical Camera. |
Aperture | Use the slider to set the ratio of the f-stop or f-number aperture. The smaller the value is, the shallower the depth of field is and more light reaches the sensor. This property affects Depth of Field if you set its Focus Mode to Use Physical Camera. This property also affects Exposure if you set its Mode to Use Physical Camera. |
Shift | Set the horizontal and vertical shift from the center. Values are multiples of the sensor size; for example, a shift of 0.5 along the X axis offsets the sensor by half its horizontal size. You can use lens shifts to correct distortion that occurs when the Camera is at an angle to the subject (for example, converging parallel lines). Shift the lens along either axis to make the Camera frustum oblique. |
Blade Count | Use the slider to set the number of diaphragm blades the Camera uses to form the aperture. This property affects the look of the Depth of Field bokeh. |
Curvature | Use the remapper to map an aperture range to blade curvature. Aperture blades become more visible on bokeh at higher aperture values. Tweak this range to define how the bokeh looks at a given aperture. The minimum value results in fully-curved, perfectly-circular bokeh, and the maximum value results in fully-shaped bokeh with visible aperture blades. This property affects the look of the Depth of Field bokeh. |
Barrel Clipping | Use the slider to set the strength of the “cat eye” effect. You can see this effect on bokeh as a result of lens shadowing (distortion along the edges of the frame). This property affects the look of the Depth of Field bokeh. |
Anamorphism | Use the slider to stretch the sensor to simulate an anamorphic look. Positive values distort the Camera vertically, negative will distort the Camera horizontally. This property affects the look of the Depth of Field bokeh and the Bloom effect if you enable its Anamorphic property. |
Output Settings
Property | Description |
---|---|
Target Display | Use the drop-down to select which device this Camera renders to. |
Target Texture | Assign a RenderTexture that this Camera renders to. If you assign this property, the Camera no longer renders to the screen. |
Depth | Set the Camera's position in the draw order. Unity processes Cameras with a smaller Depth first, then processes Cameras with a larger Depth on top. |
ViewPort Rect | Set the position and size of this Camera's output on the screen. • X: The beginning horizontal position of the output. • Y: The beginning vertical position of the output. • W: The width of the output. • H: The height of the output. |