XSIApplication.RegisterShaderCustomParameterType operator

Introduced

v9.0 (2011)

Description

Registers a new custom parameter type for shaders. This custom parameter type can be used to create new shader parameter definitions that have specific connection rules. A shader parameter of a given custom parameter type can only connect to another of the same type, unless a custom type filter is specified. This type filter is a simple flat list of parameter types, which can be either custom or built-in types (see siShaderParameterDataType for the list of string representations of the built-in types).

In addition, the custom parameter type can also restrict the type of shaders connecting to it, by specifying a list of allowed family types. The family filter is applied to all shaders in the sub-tree defined by the shader (the source) being connected into the shader parameter of the custom parameter type (the target).

C# Syntax

XSIApplication.RegisterShaderCustomParameterType( String in_name, String in_DisplayName, String in_description, Int32 in_portRed, Int32 in_portGreen, Int32 in_portBlue, Object in_typeFilter, Object in_familyFilter );

Scripting Syntax

XSIApplication.RegisterShaderCustomParameterType( in_name, in_displayName, [in_description], [in_portRed], [in_portGreen], [in_portBlue], [in_typeFilter], [in_familyFilter] );

Parameters

Parameter Type Description
in_name String The port's intrinsic name. Used when creating a shader port.
in_displayName String The port's descriptive name to be used in the UI.
in_description String A short description of the port for information purposes.

Default Value: ""

in_portRed Long The red color component for the port display. Range: 0-255.

Default Value: 0

in_portGreen Long The green color component for the port display. Range: 0-255.

Default Value: 0

in_portBlue Long The blue color component for the port display. Range: 0-255.

Default Value: 0

in_typeFilter String or SafeArray of strings List of other port types from which this port type allows connections into
in_familyFilter String or SafeArray of strings List of shader families that can connect into this port

See Also

ShaderParamDef.DataType ShaderParameter.DataType ShaderParamDefContainer.AddArrayParamDef ShaderParamDefContainer.AddParamDef