File tree Expand file tree Collapse file tree
com.unity.render-pipelines.high-definition Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -66,6 +66,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
6666- Fixed issue with lookdev shadows looking wrong upon exiting playmode.
6767- Fixed temporary Editor freeze when selecting AOV output in graphics compositor (case 1288744).
6868- Fixed normal flip with double sided materials.
69+ - Fixed XR shadows culling
6970
7071### Changed
7172- Combined occlusion meshes into one to reduce draw calls and state changes with XR single-pass.
Original file line number Diff line number Diff line change @@ -3256,6 +3256,10 @@ out ScriptableCullingParameters cullingParams
32563256 if ( hdCamera . xr . enabled )
32573257 {
32583258 cullingParams = hdCamera . xr . cullingParams ;
3259+
3260+ // Sync the FOV on the camera to match the projection from the XR device in order to cull shadows accurately
3261+ if ( ! camera . usePhysicalProperties )
3262+ camera . fieldOfView = Mathf . Rad2Deg * Mathf . Atan ( 1.0f / cullingParams . stereoProjectionMatrix . m11 ) * 2.0f ;
32593263 }
32603264 else
32613265 {
You can’t perform that action at this time.
0 commit comments