Lighting

Updated for 2021 LTS: The definitive guide to lighting in the High Definition Render Pipeline

The definitive guide to lighting in the High Definition Render Pipeline (HDRP) is now updated with tips for taking on the latest capabilities in Unity 2021 LTS. Learn how to create high-end lighting with production-ready HDRP features – from Light Anchors to Lens Flares, and beyond. This e-book was initially created and published late last year to demonstrate the power of physically based lighting in HDRP for generating high-end lighting effects across PC and console games. We’ve received positive feedback from our users, and have since updated the guide to include key features in Unity 2021 LTS. This way, it can remain a foundational, advanced-level resource for technical artists, lighting artists, and developers working in Unity.

Read More

Smoke, mirrors, and scrolling textures: Behind the scenes of TUNIC

To ensure optimal performance, Shouldice used dynamic lighting and Global Illumination (GI) in TUNIC, and carefully considered the light count: “Because deferred rendering isn’t supported with ortho cams, light count was something I needed to keep an eye on. I used precomputed GI to do a lot of the lighting rather than Point lights, and leaned on batching to keep draw calls down.” He used to write shaders by hand, but decided to use Shader Forge’s node-based shaders for TUNIC. “Even though I can write code, I’m a fairly visual person, so it was freeing to be able to see live previews and organize my thoughts spatially,” continues Shouldice. “The node editor clicked with my brain in a really nice way. It’s supremely noodly, and so much fun!” Shouldice also made extensive use of scrolling textures to light up elements of the game world, substantially reducing the complexity of the task while achieving gorgeous (and highly performant) results. Early in the game, TUNIC’s hero opens a golden doorway by interacting with a statue that emits a pulse of light when touched. Shouldice achieves this effect by using a few different components in the Unity Editor and Shader Forge. The initial points of light – known as “starburst” – derive from three animated meshes, each rotating slightly out of sync. A donut-shaped “aura ring” surrounds these meshes, and by projecting a scrolling UV texture along this flattened cylinder, Shouldice makes the texture scroll outward, creating a radial glow. For this effect, UV coordinates are scrolled and multiplied before they’re inverted at the end to create the glow’s white-on-black effect. By applying the scrolling texture to different meshes, Shouldice was able to change the glow’s behavior. In another example, he funnels the texture up a narrow, cone-shaped mesh to create the effect of magical energy coalescing skyward.

Read More