diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-03-08 15:34:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-08 15:34:08 +0100 |
commit | 6046d3babb67117a2d4ad51ccd3f4c6765b2ee9a (patch) | |
tree | fd44d289138d02eea0fc144503c92574064d6bbe /doc/classes | |
parent | 45fa14e1ae2740cef7c9396e671c0754191c7117 (diff) | |
parent | 4d6790e9dfe5dcb0cde9372ae8e731b5306e13b3 (diff) |
Merge pull request #57769 from Chaosus/vs_custom
Diffstat (limited to 'doc/classes')
-rw-r--r-- | doc/classes/VisualShaderNodeCustom.xml | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/doc/classes/VisualShaderNodeCustom.xml b/doc/classes/VisualShaderNodeCustom.xml index 7b992abe24..0a962a4aa4 100644 --- a/doc/classes/VisualShaderNodeCustom.xml +++ b/doc/classes/VisualShaderNodeCustom.xml @@ -44,6 +44,17 @@ Defining this method is [b]optional[/b]. </description> </method> + <method name="_get_func_code" qualifiers="virtual const"> + <return type="String" /> + <argument index="0" name="mode" type="int" enum="Shader.Mode" /> + <argument index="1" name="type" type="int" enum="VisualShader.Type" /> + <description> + Override this method to add a shader code to the beginning of each shader function (once). The shader code should be returned as a string, which can have multiple lines (the [code]"""[/code] multiline string construct can be used for convenience). + If there are multiple custom nodes of different types which use this feature the order of each insertion is undefined. + You can customize the generated code based on the shader [code]mode[/code] (see [enum Shader.Mode]) and/or [code]type[/code] (see [enum VisualShader.Type]). + Defining this method is [b]optional[/b]. + </description> + </method> <method name="_get_global_code" qualifiers="virtual const"> <return type="String" /> <argument index="0" name="mode" type="int" enum="Shader.Mode" /> @@ -114,11 +125,20 @@ Defining this method is [b]optional[/b]. If not overridden, no return icon is shown. </description> </method> + <method name="_is_available" qualifiers="virtual const"> + <return type="bool" /> + <argument index="0" name="mode" type="int" enum="Shader.Mode" /> + <argument index="1" name="type" type="int" enum="VisualShader.Type" /> + <description> + Override this method to prevent the node to be visible in the member dialog for the certain [code]mode[/code] (see [enum Shader.Mode]) and/or [code]type[/code] (see [enum VisualShader.Type]). + Defining this method is [b]optional[/b]. If not overridden, it's [code]true[/code]. + </description> + </method> <method name="_is_highend" qualifiers="virtual const"> <return type="bool" /> <description> Override this method to enable high-end mark in the Visual Shader Editor's members dialog. - Defining this method is [b]optional[/b]. If not overridden, it's false. + Defining this method is [b]optional[/b]. If not overridden, it's [code]false[/code]. </description> </method> </methods> |