Unity HDRP Cinematic Lighting

Lights, the physical camera, lighting modes, shadows, Volumes and ray tracing

Chapter 7: Light Types and Parameters

This is Part 3 of the Unity HDRP production guide, continuing from Part 2: Materials and Shaders. This installment covers cinematic lighting: the four HDRP light types, the physical camera and exposure, and HDRP's lighting modes and shadow system.

7.1 The Four Light Types

Unity HDRP offers four fundamental light types, each simulating a distinct lighting behavior.

Directional Light simulates an infinitely distant source, like the sun or moon - every ray is parallel regardless of the light's position in the scene. It lights the whole scene uniformly, doesn't attenuate with distance, casts parallel shadows (optimized shadow mapping), and only its rotation affects lighting (position is ignored). Used for the main outdoor light source - sun or moon. Key parameters: Intensity (in Lux for physical mode - a midday sun sits around 80,000-120,000 lux), Color, Angular Diameter (the sun's apparent size, affecting shadow softness: 0° gives razor-hard shadows like an infinitely small point source, 0.5-1.0° gives the softly feathered edges a real sun actually casts).

Point Light emits light in every direction from a single point, like a bare bulb - omnidirectional emission, inverse-square distance attenuation, shadows cast in every direction (more expensive). Used for bulbs, lamps, point sources, magic effects. Key parameters: Intensity (Lumens in physical mode), Range, Shape (Sphere or Box), Radius (source size, affects shadow softness).

Spot Light projects a cone of light in a specific direction, like a stage spotlight or flashlight - directional conical emission, radial and angular attenuation, ideal for directed, dramatic lighting. Used for spotlights, desk lamps, accent lighting, headlights. Key parameters: Spot Angle, Inner/Outer Spot Percent (transition between core and edge), Range, Shape (Cone, Pyramid, Box).

Area Light is an emissive surface producing soft, realistic light, similar to a window or a studio LED panel - naturally soft shadows, superior realism for architectural lighting, more computationally expensive (baked recommended for performance). Used for windows, studio softboxes, neon, screens, lit ceilings. Key parameters: Shape (Rectangle, Disc, Tube), Width/Height, Intensity (Lumens or Nits).

Good to know - real-time Area Lights are expensive. For projects with many Area Lights, prefer Baked mode or use Ray Tracing if the hardware allows it.

7.2 HDRP-Specific Parameters

HDRP adds advanced parameters to standard lights for finer control and greater realism. Shape affects the physical form of the emission and, in turn, the look of specular highlights and shadow softness: Point lights can be Sphere or Box, Spot lights Cone, Pyramid or Box, Area lights Rectangle, Disc or Tube. The larger the source, the softer the shadows and more diffuse the specular highlights.

HDRP uses real photometric units for light intensity:

UnitUsed forExample value
LuxDirectional Light100,000 lux (sun)
LumensPoint, Spot, Area800 lm (60W bulb)
CandelaPoint, SpotDirectional intensity
NitsArea Light (emissive)500-1000 nits (screen)
EVAllRelative exposure

Physical units make it much easier to stay consistent with real-world references and the Physical Camera. Instead of an arbitrary color, you can also set Color Temperature in Kelvin:

TemperatureLookExample
1,850 KWarm orangeCandle
2,700 KWarm whiteIncandescent bulb
4,000 KNeutral whiteCompact fluorescent
5,500 KDaylightMidday sun
6,500 KCool whiteOvercast sky
10,000+ KCool blueBlue sky

Enable it via the "Use Color Temperature" checkbox in the light's settings.

7.3 IES Profiles and Cookies

IES (Illuminating Engineering Society) files contain real photometric data from actual light fixtures, defining the precise angular distribution a real lamp emits - giving faithful reproduction of existing fixtures, more architectural realism, and physically correct light distribution. Assign a .ies file in a light's IES Profile slot.

Good to know - many fixture manufacturers provide IES files for their products free of charge, and free libraries also exist online.

Cookies are textures projected by a light to create shadow or color patterns - venetian blinds casting shadow lines, stained glass, foliage casting organic shadows, stage-light gobos. To configure: create or import a texture (grayscale for shadows, RGBA for color), assign it to the light's Cookie parameter, adjust scale and tiling as needed. Cookies work especially well on Spot and Directional Lights.

7.4 Light Rigs and Standard Setups

A Light Rig is a preconfigured set of lights for coherent lighting. The classic film/photography setup is three-point lighting:

LightRoleRelative intensity
Key LightMain light, defines the shadows100%
Fill LightSoftens shadows, reduces contrast30-50%
Rim LightSeparates the subject from the background, adds depth70-100%

Key and Fill sit roughly 45° either side of the subject, facing the camera; Rim sits behind, opposite the camera.

Outdoor daytime setup: a Directional Light (sun) at high intensity (100,000 lux), warm color (5,500 K), shadows enabled; Environment Lighting (sky) via HDRI or the Sky system for ambient light; an optional bounce light as artificial fill for deep shadow areas.

Indoor setup with windows: Area Lights at the windows simulating incoming daylight; Point/Spot Lights for practical lamps visible in the scene; ambient light via Light Probes or SSGI for indirect illumination.

Studio product visualization is a good worked example of the three-point ratio in real units: a 1.5×1.5m Area Rectangle key at 4000 lm, 5500K, positioned above and to one side; a larger 2×2m Area Rectangle fill opposite it at 1200 lm (a 3:1 ratio) and a cooler 6500K to read as ambient rather than a second key; a Spot rim behind the subject at 5000 lm and a warmer-shifted 7500K for cool separation from the background; and a subtle horizontal bounce card underneath (3×3m Area Rectangle, ~500 lm) to lift shadow density the way a real product table would. A grey or white cyclorama with high roughness, lit only by the fill's spill rather than its own dedicated light, keeps the background from competing with the subject. Shoot it with a longer focal length (85-135mm) at a moderate aperture (f/5.6) to avoid the perspective distortion a wide lens would put on a close-up product.

7.5 Light Layers

Light Layers let you precisely control which objects are lit by which lights, using an 8-layer bitmask: each light has a Light Layer parameter, each object (Mesh Renderer) has a Rendering Layer Mask, and an object is only lit if its layer matches the light's layer. Enable via Edit → Project Settings → HDRP Global Settings → Lighting → Light Layers.

SituationSetup
Studio lightingKey light only on the character (Layer 1), not the background
OptimizationExclude distant objects from expensive lights
Stylized effectsNeon that only lights certain elements
Interior/exterior separationIndoor lamps that don't affect the visible exterior

Example: a decorative neon set to Layer 1 lights only nearby walls (also Layer 1), not characters (Layer Default).

Chapter 8: Exposure and the Physical Camera

8.1 The Physical Camera

The Physical Camera simulates a real camera's behavior - its parameters match a real camera's exactly, which makes life easier for cinematographers used to real gear. Enable it via the Camera component's Projection section (check "Physical Camera").

Optical parameterDescriptionTypical values
Focal LengthFocal distance in mm35mm (wide), 50mm (standard), 85mm (portrait), 200mm (tele)
Sensor SizeSensor dimensionsFull Frame 35mm by default
Lens ShiftOptical shift (perspective correction)0 by default
Gate FitAspect ratio fittingHorizontal or Vertical
Exposure parameterDescriptionEffect
ISOSensor sensitivityHigher = brighter, more noise
Aperture (f-stop)Diaphragm openingf/1.4 = wide open (bright, shallow DoF); f/16 = closed (dark, deep DoF)
Shutter SpeedExposure timeAffects motion blur and exposure

These three form photography's classic exposure triangle: doubling ISO = +1 stop; opening one stop (e.g. f/4 → f/2.8) = +1 stop; doubling exposure time = +1 stop.

8.2 Clipping Planes

ParameterDescriptionRecommended value
NearMinimum render distance0.1 to 0.3 m
FarMaximum render distance1,000 to 10,000 m depending on the scene
Careful - too small a Near Clipping Plane (e.g. 0.01) can cause Z-buffer precision problems: visual artifacts, flickering, Z-fighting. Too large a Far wastes precision. Set these based on your scene's actual needs.

8.3 Anti-Aliasing

TAA (Temporal Anti-Aliasing) uses previous frames to smooth the image through temporal accumulation - excellent overall quality, also smooths noise from effects like SSR/SSGI, and is the recommended default; downsides are possible ghosting on fast motion and slight softening of very fine detail. SMAA is a spatial technique analyzing only the current frame - no ghosting, sharper image, but lower quality than TAA and doesn't smooth effect noise. FXAA is fast but limited quality, reserved for very constrained hardware where other options are too expensive.

SituationRecommended AA
General use, static imagesTAA
Animation with fast motionSMAA
Very limited hardwareFXAA

Configure via Camera → Anti-aliasing.

8.4 Depth of Field

Depth of Field simulates progressive blur on out-of-focus objects, essential to a cinematic look. Configure it via a Volume Override: create or select a Volume, then Add Override → Post-processing → Depth of Field.

Modes: Off, Manual (direct control of focus distance and blur), Physical Camera (uses the camera's Aperture and Focal Length). In Manual mode, key parameters are Focus Distance, Near/Far Start-End (blur transition ranges), and Near/Far Max Blur. In Physical Camera mode, it's just Focus Distance and Quality (Near/Medium/High, affecting bokeh) - depth of field is computed automatically from the camera's Aperture and Focal Length, exactly as in real photography.

Good to know - Depth of Field is essential for directing the viewer's attention, but overusing it can disorient. Use it deliberately, with narrative intent.

8.5 Controlling Exposure

Three complementary approaches: adjusting lights individually (precise per-light control, but can get complex with many sources - work in physical units for consistency), the Physical Camera's exposure parameters (ISO, Aperture, Shutter Speed) for global brightness control with a familiar photographic workflow (though Aperture also affects DoF), and post-processing Exposure via a Volume override with modes Fixed, Automatic (based on average scene luminance), Curve Mapping, or Physical Camera.

Recommendation: combine all three - set physically correct light intensities, use the Physical Camera for base exposure, and fine-tune with post-process Exposure if needed.

Chapter 9: Lighting Modes and the Shadow System

9.1 The Three Lighting Modes

Realtime Lighting computes lighting every frame. Lights and objects can move freely, full flexibility for dynamic scenes, and changes show immediately in the editor - but it's performance-expensive, indirect lighting is limited without extra techniques (SSGI, RT), and there's no natural light bounce. Best for fully dynamic scenes and prototyping.

Baked Lighting precomputes lighting and stores it in lightmap textures: mark objects as Static, set lights to Baked mode, then run Window → Rendering → Lighting → Generate Lighting. Excellent runtime performance ("free" lighting), high-quality indirect light with multiple bounces, soft realistic shadows - but only for static objects, potentially long bake times, and it costs disk/memory for the lightmaps. Best for architectural environments, fixed sets, ArchViz.

Mixed Lighting is a hybrid: static objects get baked lighting, dynamic objects get realtime lighting, and lights set to Mixed light both. Best of both worlds - dynamic characters correctly lit within baked environments - at the cost of more complex setup and an intermediate performance cost. Best for games with fixed environments and moving characters, interactive ArchViz.

9.2 Configuring Lightmapping

The Static checkbox in the Inspector tells Unity an object will never move, enabling lightmap baking inclusion, culling/batching optimizations, and navmesh contribution.

Careful - only mark permanently immobile elements as Static (architecture, fixed sets). Characters, vehicles and moving doors must stay non-static.

Baking settings (Window → Rendering → Lighting): Lightmapper (Progressive CPU, Progressive GPU, or the deprecated Enlighten), Direct Samples, Indirect Samples, Bounces, Lightmap Resolution (texels per unit), Lightmap Size. Start with low values to iterate quickly, then raise them for the final render - Progressive GPU is usually faster with a capable GPU.

Light Probes capture indirect lighting at specific scene points so dynamic objects can receive it (GameObject → Light → Light Probe Group) - place them where dynamic objects will move, denser where lighting varies more, sparser in uniformly lit areas. Reflection Probes capture environment reflections, either Baked (captured once), Realtime (updated continuously, expensive) or Custom (a manually assigned cubemap) - place them at room centers or distinct zones with an appropriate influence volume.

9.3 Advanced Shadow System

Cascade Shadow Maps split view distance into several sections, each with its own shadow map - near cascades get more resolution for sharp shadows, distant cascades get less for efficiency. Configure via HDRP Settings → Shadows: Max Distance, Cascade Count (1-4), Cascade Splits, Resolution.

Contact Shadows add fine, precise shadows at contact points between objects, essential for detail like dense vegetation or objects resting on surfaces (enable on the Light component). Shadow Filtering softens shadow edges: PCF (basic Percentage Closer Filtering), PCSS (Percentage Closer Soft Shadows, softness varies with distance), Moment Based (advanced filtering for very soft shadows). Screen Space Shadows use depth information to add fine shadow detail, enabled in HDRP Settings.

9.4 Volumes: Global and Local

Volumes are containers for rendering and post-processing settings that define a scene's visual look. It's worth distinguishing them clearly from HDRP Settings:

ElementFunctionScope
HDRP SettingsMaster pipeline configurationWhole project
VolumesRendering and post-process settingsPer zone or global

HDRP Settings define which features are available; Volumes define how those features are configured for a scene or zone.

Careful - some features must be enabled in HDRP Settings BEFORE they can be used in a Volume. If an option doesn't appear, check the global Settings first.

A Global Volume (GameObject → Volume → Global Volume) affects the whole scene regardless of camera position - used for base tone mapping/exposure, ambient occlusion and global reflections, default indirect-lighting settings, subtle project-wide effects (vignette, light bloom). A Local Volume (GameObject → Volume → Box/Sphere Volume) has a collider and only affects the camera when it's inside - used for different moods per zone (indoor vs. outdoor), automatic exposure adjustment by environment, room-specific effects (fog, color grading), atmosphere transitions.

Volumes stack and blend by Priority (a higher-priority Volume overrides others), Blend Distance (transition distance) and Weight (0-1 influence) - typically a Global Volume at Priority 0 as the base, with Local Volumes at increasing priorities as progressive overrides.

9.5 Real-Time Indirect Lighting Techniques

For scenes that need dynamic indirect lighting without baking, HDRP offers several screen-space techniques. SSGI (Screen Space Global Illumination) simulates indirect lighting by analyzing what's visible on screen (enable via HDRP Settings → Lighting → Screen Space Global Illumination, plus an SSGI override in a Volume) - dynamic indirect light that works on non-static objects and looks convincing in many scenes, but is limited to on-screen content, is expensive, and can produce edge artifacts.

SSR (Screen Space Reflections) computes reflections from on-screen depth information (HDRP Settings → Lighting → Screen Space Reflection, plus an SSR override) - used for reflective surfaces (polished metal, water, glass), with the same on-screen-only limitation as SSGI. SSAO (Screen Space Ambient Occlusion) darkens areas ambient light struggles to reach (corners, crevices, intersections) via an Ambient Occlusion Volume override - meaningfully improves depth perception at relatively low cost, and is worth enabling almost by default.

The three complement each other: SSAO for base depth (low cost), SSGI for dynamic indirect light (medium-high cost), SSR for reflections on glossy surfaces (medium cost). On limited hardware, prioritize SSAO, then SSR, then SSGI depending on the performance budget.

9.6 Introduction to Ray Tracing

HDRP supports ray tracing for high-quality effects on compatible hardware:

RequirementNeeded
GPUNVIDIA RTX 20xx+ or AMD RX 6000+
OSWindows 10/11
APIDirectX 12
VRAM8 GB minimum, 12+ GB recommended
Unity2021.2+ for RT, 2022.2+ for optimal path tracing

Enable via Player Settings → Graphics API → DirectX 12, then HDRP Settings → Frame Settings → Ray Tracing, and turn on individual effects: RT Reflections (accurate, even off-screen), RT Shadows (physically correct), RT Ambient Occlusion (precise, artifact-free), RT Global Illumination (high-quality dynamic indirect light), and Path Tracing (full offline light simulation).

AspectScreen SpaceRay Tracing
PerformanceBetterMore expensive
AccuracyLimited to on-screenComplete
HardwareStandardRTX required
NoiseNoYes (needs denoising)

Path Tracing is the most realistic rendering mode, exhaustively simulating every possible light path - cinematic quality comparable to Arnold or V-Ray, physically correct global illumination, progressive convergence (the image improves over time), and it's not real-time (offline rendering). Enable via HDRP Settings → Lighting → Path Tracing, then hit Play to start the progressive render.

Careful - Path Tracing is very expensive. Not recommended for beginners; reserve it for high-quality final renders when you have the time.

Part 3 Summary

ChapterSkills covered
Ch. 7 - LightsLight types, HDRP parameters, IES, Cookies, Light Layers
Ch. 8 - CameraPhysical Camera, exposure, clipping, anti-aliasing, DoF
Ch. 9 - ModesRealtime/Mixed/Baked, lightmapping, shadows, Volumes, SSGI, Ray Tracing

Key takeaways: physical units (Lux, Lumens, Kelvin) make consistent, realistic lighting much easier; the Physical Camera gives an intuitive, photography-native workflow; the Realtime/Mixed/Baked choice comes down to a quality/performance/flexibility trade-off; Volumes give granular per-zone control; Light Layers enable selective lighting; screen-space techniques (SSAO, SSGI, SSR) round out base lighting; and Ray Tracing delivers the best quality on compatible hardware.

Part 4, next, covers advanced rendering in detail: ray tracing and path tracing workflows, post-processing, and export for cinematic production.