2022-08-27 17:22:43 +08:00
<?xml version="1.0" encoding="UTF-8" ?>
2023-07-06 16:08:05 +08:00
<class name= "VisualShaderNodeIntParameter" inherits= "VisualShaderNodeParameter" xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation= "../class.xsd" >
2022-08-27 17:22:43 +08:00
<brief_description >
2022-12-07 22:59:34 +08:00
A visual shader node for shader parameter (uniform) of type [int].
2022-08-27 17:22:43 +08:00
</brief_description>
<description >
2022-12-07 22:59:34 +08:00
A [VisualShaderNodeParameter] of type [int]. Offers additional customization for range of accepted values.
2022-08-27 17:22:43 +08:00
</description>
<tutorials >
</tutorials>
<members >
<member name= "default_value" type= "int" setter= "set_default_value" getter= "get_default_value" default= "0" >
2022-12-07 22:59:34 +08:00
Default value of this parameter, which will be used if not set externally. [member default_value_enabled] must be enabled; defaults to [code]0[/code] otherwise.
2022-08-27 17:22:43 +08:00
</member>
<member name= "default_value_enabled" type= "bool" setter= "set_default_value_enabled" getter= "is_default_value_enabled" default= "false" >
2022-12-07 22:59:34 +08:00
If [code]true[/code], the node will have a custom default value.
2022-08-27 17:22:43 +08:00
</member>
2024-07-14 02:30:08 +08:00
<member name= "enum_names" type= "PackedStringArray" setter= "set_enum_names" getter= "get_enum_names" default= "PackedStringArray()" >
The names used for the enum select in the editor. [member hint] must be [constant HINT_ENUM] for this to take effect.
</member>
2022-08-27 17:22:43 +08:00
<member name= "hint" type= "int" setter= "set_hint" getter= "get_hint" enum= "VisualShaderNodeIntParameter.Hint" default= "0" >
2022-12-07 22:59:34 +08:00
Range hint of this node. Use it to customize valid parameter range.
2022-08-27 17:22:43 +08:00
</member>
<member name= "max" type= "int" setter= "set_max" getter= "get_max" default= "100" >
2022-12-07 22:59:34 +08:00
The maximum value this parameter can take. [member hint] must be either [constant HINT_RANGE] or [constant HINT_RANGE_STEP] for this to take effect.
2022-08-27 17:22:43 +08:00
</member>
<member name= "min" type= "int" setter= "set_min" getter= "get_min" default= "0" >
2022-12-07 22:59:34 +08:00
The minimum value this parameter can take. [member hint] must be either [constant HINT_RANGE] or [constant HINT_RANGE_STEP] for this to take effect.
2022-08-27 17:22:43 +08:00
</member>
<member name= "step" type= "int" setter= "set_step" getter= "get_step" default= "1" >
2022-12-07 22:59:34 +08:00
The step between parameter's values. Forces the parameter to be a multiple of the given value. [member hint] must be [constant HINT_RANGE_STEP] for this to take effect.
2022-08-27 17:22:43 +08:00
</member>
</members>
<constants >
<constant name= "HINT_NONE" value= "0" enum= "Hint" >
2022-12-07 22:59:34 +08:00
The parameter will not constrain its value.
2022-08-27 17:22:43 +08:00
</constant>
<constant name= "HINT_RANGE" value= "1" enum= "Hint" >
2022-12-07 22:59:34 +08:00
The parameter's value must be within the specified [member min]/[member max] range.
2022-08-27 17:22:43 +08:00
</constant>
<constant name= "HINT_RANGE_STEP" value= "2" enum= "Hint" >
2022-12-07 22:59:34 +08:00
The parameter's value must be within the specified range, with the given [member step] between values.
2022-08-27 17:22:43 +08:00
</constant>
2024-07-14 02:30:08 +08:00
<constant name= "HINT_ENUM" value= "3" enum= "Hint" >
The parameter uses an enum to associate preset values to names in the editor.
</constant>
<constant name= "HINT_MAX" value= "4" enum= "Hint" >
2022-12-07 22:59:34 +08:00
Represents the size of the [enum Hint] enum.
2022-08-27 17:22:43 +08:00
</constant>
</constants>
</class>