浏览代码

[ReflectionProbe] Fixed multiselection with mixed values

/main
Frédéric Vauchelles 7 年前
当前提交
a4860f0b
共有 1 个文件被更改,包括 9 次插入1 次删除
  1. 10
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Reflection/HDReflectionProbeUI.Drawers.cs

10
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Reflection/HDReflectionProbeUI.Drawers.cs


var blendDistance = p.blendDistancePositive.vector3Value.x;
EditorGUI.BeginChangeCheck();
EditorGUI.showMixedValue = p.blendDistancePositive.hasMultipleDifferentValues;
blendDistance = EditorGUILayout.Slider(CoreEditorUtils.GetContent("Blend Distance|Area around the probe where it is blended with other probes. Only used in deferred probes."), blendDistance, 0, maxBlendDistance);
if (EditorGUI.EndChangeCheck())
{

var blendNormalDistance = p.blendNormalDistancePositive.vector3Value.x;
EditorGUI.BeginChangeCheck();
EditorGUI.showMixedValue = p.blendNormalDistancePositive.hasMultipleDifferentValues;
blendNormalDistance = EditorGUILayout.Slider(CoreEditorUtils.GetContent("Blend Normal Distance|Area around the probe where the normals influence the probe. Only used in deferred probes."), blendNormalDistance, 0, maxBlendDistance);
if (EditorGUI.EndChangeCheck())
{

EditorGUI.showMixedValue = false;
EditorGUILayout.PropertyField(p.influenceSphereRadius, CoreEditorUtils.GetContent("Radius"));
EditorGUILayout.PropertyField(p.boxOffset, CoreEditorUtils.GetContent("Sphere Offset|The center of the sphere in which the reflections will be applied to objects. The value is relative to the position of the Game Object."));

{
EditorGUILayout.PropertyField(p.renderDynamicObjects, CoreEditorUtils.GetContent("Dynamic Objects|If enabled dynamic objects are also rendered into the cubemap"));
p.customBakedTexture.objectReferenceValue = EditorGUILayout.ObjectField(CoreEditorUtils.GetContent("Cubemap"), p.customBakedTexture.objectReferenceValue, typeof(Cubemap), false);
EditorGUI.showMixedValue = p.customBakedTexture.hasMultipleDifferentValues;
EditorGUI.BeginChangeCheck();
var customBakedTexture = EditorGUILayout.ObjectField(CoreEditorUtils.GetContent("Cubemap"), p.customBakedTexture.objectReferenceValue, typeof(Cubemap), false);
EditorGUI.showMixedValue = false;
if (EditorGUI.EndChangeCheck())
p.customBakedTexture.objectReferenceValue = customBakedTexture;
}
static void Drawer_ModeSettingsRealtime(HDReflectionProbeUI s, SerializedHDReflectionProbe p, Editor owner)

正在加载...
取消
保存