浏览代码

[ReflectionProbeEditor] Force probe to be cube type and not quad

/feature-ReflectionProbeFit
Frédéric Vauchelles 7 年前
当前提交
d2f52683
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/HDReflectionProbeEditor.ProbeUtility.cs

7
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/HDReflectionProbeEditor.ProbeUtility.cs


var a = (HDAdditionalReflectionData)m_AdditionalDataSerializedObject.targetObjects[i];
InitializeProbe(p, a);
}
// For an unknown reason, newly created probes sometype have the type "Quad" (value = 1)
// This type of probe is not supported by Unity since 5.4
// But we need to force it here so it does not bake into a 2D texture but a Cubemap
serializedObject.Update();
serializedObject.FindProperty("m_Type").intValue = 0;
serializedObject.ApplyModifiedProperties();
}

正在加载...
取消
保存