浏览代码

[PlanarReflection] updated UI

/main
Frédéric Vauchelles 7 年前
当前提交
1c4b9f20
共有 5 个文件被更改,包括 70 次插入26 次删除
  1. 3
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeEditor.cs
  2. 61
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeUI.Drawers.cs
  3. 7
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeUI.cs
  4. 19
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Volume/InfluenceVolumeUI.Drawers.cs
  5. 6
      ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Volume/InfluenceVolumeUI.cs

3
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeEditor.cs


using System.Collections.Generic;
using UnityEngine.Experimental.Rendering;
using System.Collections.Generic;
using UnityEngine.Experimental.Rendering.HDPipeline;
namespace UnityEditor.Experimental.Rendering.HDPipeline

61
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeUI.Drawers.cs


using System;
using System;
using UnityEditorInternal;
using UnityEngine;

partial class PlanarReflectionProbeUI
{
public static readonly CED.IDrawer Inspector = CED.Group(
CED.Action(Drawer_SectionPrimarySettings),
CED.space,
CED.Action((s, d, o) => EditorGUILayout.LabelField(_.GetContent("Proxy Volume"), EditorStyles.boldLabel)),
CED.Action(Drawer_FieldProxyVolumeReference),
CED.space,
CED.Action((s, d, o) => EditorGUILayout.LabelField(_.GetContent("Influence Volume"), EditorStyles.boldLabel)),
CED.Action(Drawer_Toolbar),
CED.space,
CED.Select(
(s, d, o) => s.influenceVolume,
(s, d, o) => d.influenceVolume,
InfluenceVolumeUI.SectionShape
)
public static readonly CED.IDrawer Inspector;
public static readonly CED.IDrawer SectionCaptureSettings = CED.Group(
CED.Action(Drawer_SectionCaptureSettings)
);
public static readonly CED.IDrawer SectionFoldoutAdvancedSettings = CED.FoldoutGroup(
"Advanced Settings",
(s, d, o) => s.isSectionExpandedAdvancedSettings,
true,
CED.Action(Drawer_SectionAdvancedSettings)
static PlanarReflectionProbeUI()
{
Inspector = CED.Group(
SectionCaptureSettings,
CED.space,
CED.Action((s, d, o) => EditorGUILayout.LabelField(_.GetContent("Proxy Volume"), EditorStyles.boldLabel)),
CED.Action(Drawer_FieldProxyVolumeReference),
CED.space,
CED.Action(Drawer_Toolbar),
CED.space,
CED.Select(
(s, d, o) => s.influenceVolume,
(s, d, o) => d.influenceVolume,
InfluenceVolumeUI.SectionFoldoutShape
),
SectionFoldoutAdvancedSettings
);
}
static void Drawer_SectionPrimarySettings(PlanarReflectionProbeUI s, SerializedPlanarReflectionProbe d, Editor o)
static void Drawer_SectionAdvancedSettings(PlanarReflectionProbeUI s, SerializedPlanarReflectionProbe d, Editor o)
{
EditorGUILayout.PropertyField(d.dimmer, _.GetContent("Dimmer"));
}
static void Drawer_SectionCaptureSettings(PlanarReflectionProbeUI s, SerializedPlanarReflectionProbe d, Editor o)
EditorGUILayout.PropertyField(d.mode, _.GetContent("Mode"));
EditorGUILayout.LabelField(_.GetContent("Capture Settings"), EditorStyles.boldLabel);
++EditorGUI.indentLevel;
EditorGUILayout.PropertyField(d.mode, _.GetContent("Type"));
EditorGUILayout.PropertyField(d.dimmer, _.GetContent("Dimmer"));
--EditorGUI.indentLevel;
}
static void Drawer_FieldProxyVolumeReference(PlanarReflectionProbeUI s, SerializedPlanarReflectionProbe d, Editor o)
{

7
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/PlanarReflectionProbeUI.cs


using UnityEngine.Events;
using UnityEditor.AnimatedValues;
using UnityEngine.Events;
namespace UnityEditor.Experimental.Rendering.HDPipeline
{

public AnimBool isSectionExpandedAdvancedSettings { get { return m_AnimBools[0]; } }
: base(0)
: base(1)
{
}

19
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Volume/InfluenceVolumeUI.Drawers.cs


using UnityEngine;
using UnityEngine;
using UnityEngine.Experimental.Rendering.HDPipeline;
namespace UnityEditor.Experimental.Rendering.HDPipeline

partial class InfluenceVolumeUI
{
public static readonly CED.IDrawer SectionShape;
public static readonly CED.IDrawer SectionFoldoutShape;
public static readonly CED.IDrawer FieldShape = CED.Action(Drawer_FieldShapeType);
public static readonly CED.IDrawer SectionShapeBox = CED.Action(Drawer_SectionShapeBox);
public static readonly CED.IDrawer SectionShapeSphere = CED.Action(Drawer_SectionShapeSphere);

true,
SectionShapeBox,
SectionShapeSphere
)
);
SectionFoldoutShape = CED.Group(
CED.FoldoutGroup(
"Influence Volume",
(s, d, o) => s.isSectionExpandedShape,
true,
CED.Action(Drawer_FieldShapeType),
CED.FadeGroup(
(s, d, o, i) => s.IsSectionExpanded_Shape((ShapeType)i),
false,
SectionShapeBox,
SectionShapeSphere
)
)
);
}

6
ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Lighting/Volume/InfluenceVolumeUI.cs


using System;
using System;
using UnityEditor.AnimatedValues;
using UnityEditor.IMGUI.Controls;
using UnityEngine;

public SphereBoundsHandle sphereInfluenceHandle = new SphereBoundsHandle();
public SphereBoundsHandle sphereInfluenceNormalHandle = new SphereBoundsHandle();
public AnimBool isSectionExpandedShape { get { return m_AnimBools[k_ShapeCount]; } }
: base(k_ShapeCount)
: base(k_ShapeCount + 1)
{
}

正在加载...
取消
保存