GetInputChannel() public method

public GetInputChannel ( uint channelId ) : StrumpyShaderEditor.InputChannel
channelId uint
return StrumpyShaderEditor.InputChannel
Example #1
0
 public static Vector2 GetAbsoluteInputChannelPosition( Node node, uint channelId )
 {
     var inputChannel = node.GetInputChannel( channelId );
     var result = new Vector2( node.NodePositionInGraph.x, node.NodePositionInGraph.y);
     result += new Vector2( inputChannel.Position.x, inputChannel.Position.y );
     result += new Vector2( inputChannel.Position.width / 2, inputChannel.Position.height / 2 );
     return result;
 }
Example #2
0
        public static Vector2 GetAbsoluteInputChannelPosition(Node node, uint channelId)
        {
            var inputChannel = node.GetInputChannel(channelId);
            var result       = new Vector2(node.NodePositionInGraph.x, node.NodePositionInGraph.y);

            result += new Vector2(inputChannel.Position.x, inputChannel.Position.y);
            result += new Vector2(inputChannel.Position.width / 2, inputChannel.Position.height / 2);
            return(result);
        }