1#include "Shading/ShaderNodeEditor.h"
5SNEPin::SNEPin(NodeEditorPinType type, SNEPinType var)
15SNEPinType SNEPin::GetType()
17 return static_cast<SNEPinType
>(userData);
20void SNEPin::SetType(SNEPinType type)
26 case SNEPinType_Float:
27 color = ImColor(FLOAT_PIN_COLOR);
30 case SNEPinType_Float2:
31 color = ImColor(FLOAT2_PIN_COLOR);
34 case SNEPinType_Float3:
35 color = ImColor(FLOAT3_PIN_COLOR);
39 color = ImColor(BOOL_PIN_COLOR);
58 callerPinId = pin->id;
61 OnEvaluate(function, line);
68 SNEPin *otherPin =
nullptr;
70 if(selfPin->type == NodeEditorPinType::Input)
72 otherPin =
static_cast<SNEPin *
>(link->to);
77 otherPin =
static_cast<SNEPin *
>(link->from);
80 return (selfPin->GetType() == otherPin->GetType());