浏览代码

Fix version number in HDRP asset

/main
sebastienlagarde 6 年前
当前提交
466061e1
共有 2 个文件被更改,包括 14 次插入2 次删除
  1. 2
      com.unity.render-pipelines.high-definition/HDRP/Camera/HDAdditionalCameraData.cs
  2. 14
      com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/HDRenderPipelineAsset.cs

2
com.unity.render-pipelines.high-definition/HDRP/Camera/HDAdditionalCameraData.cs


// Tag as dirty so frameSettings are correctly initialize at next HDRenderPipeline.Render() call
m_frameSettingsIsDirty = true;
if(m_Version != currentVersion)
if (m_Version != currentVersion)
{
// Add here data migration code
m_Version = currentVersion;

14
com.unity.render-pipelines.high-definition/HDRP/RenderPipeline/HDRenderPipelineAsset.cs


public class HDRenderPipelineAsset : RenderPipelineAsset, ISerializationCallbackReceiver
{
[HideInInspector]
public float version = 1.0f;
const int currentVersion = 1;
// Currently m_Version is not used and produce a warning, remove these pragmas at the next version incrementation
#pragma warning disable 414
[SerializeField]
int m_Version = currentVersion;
#pragma warning restore 414
HDRenderPipelineAsset()
{

// When FrameSettings are manipulated we reset them to reflect the change, discarding all the Debug Windows change.
// Tag as dirty so frameSettings are correctly initialize at next HDRenderPipeline.Render() call
m_frameSettingsIsDirty = true;
if (m_Version != currentVersion)
{
// Add here data migration code
m_Version = currentVersion;
}
}
}
}
正在加载...
取消
保存