Skip to content

Hd/fix wizard runtime resources #3123

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 3 commits into from
Jan 15, 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
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 @@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed tesselation culling, big triangles using lit tesselation shader would dissapear when camera is too close to them (case 1299116)
- Fixed issue with compositor related custom passes still active after disabling the compositor (case 1305330)
- Fixed some render texture leaks.
- Fixed regression in Wizard that not fix runtime ressource anymore (case 1287627)

### Changed
- Change the source value for the ray tracing frame index iterator from m_FrameCount to the camera frame count (case 1301356).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -403,15 +403,15 @@ void FixHdrpAssetRuntimeResources(bool fromAsyncUnused)
if (hdrpAsset == null)
return;

var editorResourcesPath = HDUtils.GetHDRenderPipelinePath() + "Editor/RenderPipelineResources/HDRenderPipelineEditorResources.asset";
var objs = InternalEditorUtility.LoadSerializedFileAndForget(editorResourcesPath);
hdrpAsset.renderPipelineEditorResources = objs != null && objs.Length > 0 ? objs.First() as HDRenderPipelineEditorResources : null;
if (ResourceReloader.ReloadAllNullIn(HDRenderPipeline.defaultAsset.renderPipelineEditorResources,
var runtimeResourcesPath = HDUtils.GetHDRenderPipelinePath() + "Runtime/RenderPipelineResources/HDRenderPipelineResources.asset";
var objs = InternalEditorUtility.LoadSerializedFileAndForget(runtimeResourcesPath);
hdrpAsset.renderPipelineResources = objs != null && objs.Length > 0 ? objs.First() as RenderPipelineResources : null;
if (ResourceReloader.ReloadAllNullIn(HDRenderPipeline.defaultAsset.renderPipelineResources,
HDUtils.GetHDRenderPipelinePath()))
{
InternalEditorUtility.SaveToSerializedFileAndForget(
new UnityEngine.Object[] { HDRenderPipeline.defaultAsset.renderPipelineEditorResources },
editorResourcesPath,
new UnityEngine.Object[] { HDRenderPipeline.defaultAsset.renderPipelineResources },
runtimeResourcesPath,
true);
}
}
Expand Down