Skip to content

Fix wrong error thrown on DXR wizard fixup #2127

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
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
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 @@ -144,6 +144,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed alpha not having TAA applied to it.
- Fix issue with alpha output in forward.
- Fix compilation issue on Vulkan for shaders using high quality shadows in XR mode.
- Fixed wrong error message when fixing DXR resources from Wizard.

### Changed
- Preparation pass for RTSSShadows to be supported by render graph.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -638,8 +638,14 @@ void FixDXRAsset(bool fromAsyncUnused)
HDRenderPipeline.defaultAsset.renderPipelineRayTracingResources
= AssetDatabase.LoadAssetAtPath<HDRenderPipelineRayTracingResources>(HDUtils.GetHDRenderPipelinePath() + "Runtime/RenderPipelineResources/HDRenderPipelineRayTracingResources.asset");
ResourceReloader.ReloadAllNullIn(HDRenderPipeline.defaultAsset.renderPipelineRayTracingResources, HDUtils.GetHDRenderPipelinePath());
if (!SystemInfo.supportsRayTracing)
// IMPORTANT: We display the error only if we are D3D12 as the supportsRayTracing always return false in any other device even if OS/HW supports DXR.
// The D3D12 is a separate check in the wizard, so it is fine not to display an error in case we are not D3D12.
if (!SystemInfo.supportsRayTracing && IsDXRDirect3D12Correct())
Debug.LogError("Your hardware and/or OS don't support DXR!");
if (!HDProjectSettings.wizardNeedRestartAfterChangingToDX12 && PlayerSettings.GetGraphicsAPIs(CalculateSelectedBuildTarget()).FirstOrDefault() != GraphicsDeviceType.Direct3D12)
{
Debug.LogWarning("DXR is supported only with DX12");
}
}

bool IsDXRScreenSpaceShadowCorrect()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ public ConfigStyle(string label, string error, string button = resolve, MessageT
error: "DXR is not activated!");
public static readonly ConfigStyle dxrResources = new ConfigStyle(
label: "DXR resources",
error: "There is an issue with the DXR resources! Or your hardware and/or OS cannot be used for DXR! (unfixable in second case)");
error: "There is an issue with the DXR resources! Alternatively, Direct3D is not set as API (can be fixed with option above) or your hardware and/or OS cannot be used for DXR! (unfixable)");
public static readonly ConfigStyle dxrScene = new ConfigStyle(
label: "Default DXR scene prefab",
error: "Default DXR scene prefab must be set to create HD templated scene!");
Expand Down