Skip to content

Commit

Permalink
Revert "Fixed an issue where a warning about the static sky not being…
Browse files Browse the repository at this point in the history
… ready was wrongly displayed. (#2727)"

This reverts commit 4b1e36e.
  • Loading branch information
sebastienlagarde committed Nov 24, 2020
1 parent b695f3a commit 577ebe5
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
1 change: 0 additions & 1 deletion com.unity.render-pipelines.high-definition/CHANGELOG.md
Expand Up @@ -25,7 +25,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed normal buffer not bound to custom pass anymore.
- Fixed issues with camera management in the graphics compositor (cases 1292548, 1292549).
- Fixes some labels being clipped in the Render Graph Viewer
- Fixed an issue where a warning about the static sky not being ready was wrongly displayed.

### Changed
- Removed the material pass probe volumes evaluation mode.
Expand Down
Expand Up @@ -153,12 +153,20 @@ class SkyManager

// 2 by default: Static sky + one dynamic. Will grow if needed.
DynamicArray<CachedSkyContext> m_CachedSkyContexts = new DynamicArray<CachedSkyContext>(2);

public SkyManager()
{}

~SkyManager()
{}
public SkyManager()
{
#if UNITY_EDITOR
UnityEditor.Lightmapping.bakeStarted += OnBakeStarted;
#endif
}

~SkyManager()
{
#if UNITY_EDITOR
UnityEditor.Lightmapping.bakeStarted -= OnBakeStarted;
#endif
}

internal static SkySettings GetSkySetting(VolumeStack stack)
{
Expand Down Expand Up @@ -285,10 +293,6 @@ public void Build(HDRenderPipelineAsset hdAsset, RenderPipelineResources default
}

InitializeBlackCubemapArray();

#if UNITY_EDITOR
UnityEditor.Lightmapping.bakeStarted += OnBakeStarted;
#endif
}

void InitializeBlackCubemapArray()
Expand Down Expand Up @@ -334,7 +338,6 @@ public void Cleanup()

#if UNITY_EDITOR
CoreUtils.Destroy(m_DefaultPreviewSky);
UnityEditor.Lightmapping.bakeStarted -= OnBakeStarted;
#endif
}

Expand Down

0 comments on commit 577ebe5

Please sign in to comment.