您最多选择25个主题
主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
37 行
1.0 KiB
37 行
1.0 KiB
using UnityEngine.Graphing;
|
|
|
|
|
|
namespace UnityEngine.MaterialGraph
|
|
{
|
|
[Title("Channels/Unpack Normal Node")]
|
|
internal class UnpackNormalNode : Function1Input
|
|
{
|
|
public UnpackNormalNode()
|
|
{
|
|
name = "UnpackNormalNode";
|
|
}
|
|
|
|
public override bool hasPreview
|
|
{
|
|
get { return false; }
|
|
}
|
|
|
|
protected override MaterialSlot GetInputSlot()
|
|
{
|
|
return new MaterialSlot(InputSlotId, GetInputSlotName(), kInputSlotShaderName, SlotType.Input, SlotValueType.Vector4, Vector4.zero);
|
|
}
|
|
|
|
protected override MaterialSlot GetOutputSlot()
|
|
{
|
|
return new MaterialSlot(OutputSlotId, GetOutputSlotName(), kOutputSlotShaderName, SlotType.Output, SlotValueType.Vector3, Vector4.zero);
|
|
}
|
|
|
|
protected override string GetInputSlotName() {return "PackedNormal"; }
|
|
protected override string GetOutputSlotName() {return "Normal"; }
|
|
|
|
protected override string GetFunctionName()
|
|
{
|
|
return "UnpackNormal";
|
|
}
|
|
}
|
|
}
|