浏览代码

Make bound input types have a default slot label that identifies the space of the default input

/main
Jens Holm 7 年前
当前提交
3bff7ec6
共有 6 个文件被更改,包括 36 次插入11 次删除
  1. 7
      com.unity.shadergraph/Editor/Data/Graphs/BitangentMaterialSlot.cs
  2. 8
      com.unity.shadergraph/Editor/Data/Graphs/NormalMaterialSlot.cs
  3. 8
      com.unity.shadergraph/Editor/Data/Graphs/PositionMaterialSlot.cs
  4. 8
      com.unity.shadergraph/Editor/Data/Graphs/TangentMaterialSlot.cs
  5. 7
      com.unity.shadergraph/Editor/Data/Graphs/ViewDirectionMaterialSlot.cs
  6. 9
      com.unity.shadergraph/Editor/Resources/Styles/Controls/BoundInputVectorSlotControlView.uss

7
com.unity.shadergraph/Editor/Data/Graphs/BitangentMaterialSlot.cs


using System;
using UnityEditor.ShaderGraph.Drawing.Slots;
using UnityEngine.Experimental.UIElements;
namespace UnityEditor.ShaderGraph
{

ShaderStage shaderStage = ShaderStage.Dynamic, bool hidden = false)
: base(slotId, displayName, shaderOutputName, space, shaderStage, hidden)
{}
public override VisualElement InstantiateControl()
{
return new BoundInputVectorControlView(space + " Space");
}
public override string GetDefaultValue(GenerationMode generationMode)
{

8
com.unity.shadergraph/Editor/Data/Graphs/NormalMaterialSlot.cs


using System;
using UnityEngine;
using UnityEditor.ShaderGraph.Drawing.Slots;
using UnityEngine.Experimental.UIElements;
namespace UnityEditor.ShaderGraph
{

ShaderStage shaderStage = ShaderStage.Dynamic, bool hidden = false)
: base(slotId, displayName, shaderOutputName, space, shaderStage, hidden)
{}
public override VisualElement InstantiateControl()
{
return new BoundInputVectorControlView(space + " Space");
}
public override string GetDefaultValue(GenerationMode generationMode)
{

8
com.unity.shadergraph/Editor/Data/Graphs/PositionMaterialSlot.cs


using System;
using UnityEngine;
using UnityEditor.ShaderGraph.Drawing.Slots;
using UnityEngine.Experimental.UIElements;
namespace UnityEditor.ShaderGraph
{

ShaderStage shaderStage = ShaderStage.Dynamic, bool hidden = false)
: base(slotId, displayName, shaderOutputName, space, shaderStage, hidden)
{}
public override VisualElement InstantiateControl()
{
return new BoundInputVectorControlView(space + " Space");
}
public override string GetDefaultValue(GenerationMode generationMode)
{

8
com.unity.shadergraph/Editor/Data/Graphs/TangentMaterialSlot.cs


using System;
using UnityEngine;
using UnityEditor.ShaderGraph.Drawing.Slots;
using UnityEngine.Experimental.UIElements;
namespace UnityEditor.ShaderGraph
{

ShaderStage shaderStage = ShaderStage.Dynamic, bool hidden = false)
: base(slotId, displayName, shaderOutputName, space, shaderStage, hidden)
{}
public override VisualElement InstantiateControl()
{
return new BoundInputVectorControlView(space + " Space");
}
public override string GetDefaultValue(GenerationMode generationMode)
{

7
com.unity.shadergraph/Editor/Data/Graphs/ViewDirectionMaterialSlot.cs


using System;
using UnityEngine;
using UnityEditor.ShaderGraph.Drawing.Slots;
using UnityEngine.Experimental.UIElements;
namespace UnityEditor.ShaderGraph
{

ShaderStage shaderStage = ShaderStage.Dynamic, bool hidden = false)
: base(slotId, displayName, shaderOutputName, space, shaderStage, hidden)
{}
public override VisualElement InstantiateControl()
{
return new BoundInputVectorControlView(space + " Space");
}
public override string GetDefaultValue(GenerationMode generationMode)
{

9
com.unity.shadergraph/Editor/Resources/Styles/Controls/BoundInputVectorSlotControlView.uss


ScreenPositionSlotControlView > Label {
margin-top: 0;
margin-bottom: 0;
margin-left: 0;
margin-right: 0;
width: 54;
}
BoundInputVectorControlView > Label {
}
正在加载...
取消
保存