Skip to content

Fixed camera bridge action in release build #6313

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public static bool enabled
/// <returns>Enumeration of actions</returns>
public static IEnumerator<Action<RenderTargetIdentifier, CommandBuffer>> GetCaptureActions(Camera camera)
{
if (!actionDict.TryGetValue(camera, out var actions))
if (!actionDict.TryGetValue(camera, out var actions) || actions.Count == 0)
return null;

return actions.GetEnumerator();
Expand Down
1 change: 1 addition & 0 deletions com.unity.render-pipelines.high-definition/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed screen space shadow debug view not showing when no shadows is available.
- Fixed nullref from debug menu in release build (case 1381556).
- Fixed debug window reset.
- Fixed camera bridge action in release build (case 1367866).

### Changed
- Optimizations for the physically based depth of field.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1395,6 +1395,8 @@ public ScreenSpaceReflectionAlgorithm
MaterialPropertyBlock m_RecorderPropertyBlock = new MaterialPropertyBlock();
Rect? m_OverridePixelRect = null;

internal bool hasCaptureActions => m_RecorderCaptureActions != null;

// Keep track of the previous DLSS state
private DynamicResolutionHandler.UpsamplerScheduleType m_PrevUpsamplerSchedule = DynamicResolutionHandler.UpsamplerScheduleType.AfterPost;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -905,7 +905,7 @@ internal static bool PostProcessIsFinalPass(HDCamera hdCamera)
// Post process pass is the final blit only when not in developer mode.
// In developer mode, we support a range of debug rendering that needs to occur after post processes.
// In order to simplify writing them, we don't Y-flip in the post process pass but add a final blit at the end of the frame.
return !Debug.isDebugBuild && !WillCustomPassBeExecuted(hdCamera, CustomPassInjectionPoint.AfterPostProcess);
return !Debug.isDebugBuild && !WillCustomPassBeExecuted(hdCamera, CustomPassInjectionPoint.AfterPostProcess) && !hdCamera.hasCaptureActions;
}

// These two convertion functions are used to store GUID assets inside materials,
Expand Down