With the latest Snapdragon and Dimensity chips supporting hardware-accelerated ray tracing, I want to implement basic RT shadows and reflections in my URP project. Are there specific C# scripts or renderer features that allow for hybrid rendering without destroying the battery life of the device?
3 answers
Mobile ray tracing is still in its infancy, so the best approach is "Selective Ray Tracing." Instead of tracing the whole scene, use a custom Render Feature in URP to only trace high-gloss surfaces for reflections or specific hero objects for shadows. You must target the Vulkan Ray Tracing extensions specifically. We found that limiting the ray bounce to 1 and using a half-resolution denoising filter keeps the GPU thermal throttling at bay. On the latest RedMagic phones, we managed a stable 45fps with these optimizations, which is plenty for a high-fidelity mobile RPG.
Do you think the performance hit of RT shadows is actually worth it on a 6-inch screen compared to high-quality baked lightmaps?
Make sure to check if the device supports RayQuery in HLSL. It’s often more efficient for mobile GPUs than the full Ray Tracing Pipeline (RTP) setup.
Correct, Cheryl! Inline ray tracing via RayQuery is much less taxing on the driver overhead for mobile platforms compared to the full pipeline state objects.
Ralph, for static environments, baked lightmaps still win. But for dynamic time-of-day systems where baking isn't an option, RT shadows provide a level of grounding and contact hardening that shadow maps just can't touch. It’s more about the "wow" factor for premium devices.