Documentation
¶
Overview ¶
Package VisualShaderNodeColorOp provides methods for working with VisualShaderNodeColorOp object instances.
Index ¶
- type Advanced
- type Any
- type Extension
- func (self *Extension[T]) AsObject() [1]gd.Object
- func (self *Extension[T]) AsRefCounted() [1]gd.RefCounted
- func (self *Extension[T]) AsResource() Resource.Instance
- func (self *Extension[T]) AsVisualShaderNode() VisualShaderNode.Instance
- func (self *Extension[T]) AsVisualShaderNodeColorOp() Instance
- type ID
- type Instance
- func (self Instance) AsObject() [1]gd.Object
- func (self Instance) AsRefCounted() [1]gd.RefCounted
- func (self Instance) AsResource() Resource.Instance
- func (self Instance) AsVisualShaderNode() VisualShaderNode.Instance
- func (self Instance) AsVisualShaderNodeColorOp() Instance
- func (self Instance) ID() ID
- func (self Instance) Operator() Operator
- func (self *Instance) SetObject(obj [1]gd.Object) bool
- func (self Instance) SetOperator(value Operator)
- func (self Instance) Virtual(name string) reflect.Value
- type Operator
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Advanced ¶
type Advanced = class
Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.
type Extension ¶
Extension can be embedded in a new struct to create an extension of this class. T should be the type that is embedding this Extension
func (*Extension[T]) AsRefCounted ¶
func (self *Extension[T]) AsRefCounted() [1]gd.RefCounted
func (*Extension[T]) AsResource ¶
func (*Extension[T]) AsVisualShaderNode ¶
func (self *Extension[T]) AsVisualShaderNode() VisualShaderNode.Instance
func (*Extension[T]) AsVisualShaderNodeColorOp ¶
type ID ¶
ID is a typed object ID (reference) to an instance of this class, use it to store references to objects with unknown lifetimes, as an ID will not panic on use if the underlying object has been destroyed.
type Instance ¶
type Instance [1]gdclass.VisualShaderNodeColorOp
Applies [member operator] to two color inputs.
var Nil Instance
Nil is a nil/null instance of the class. Equivalent to the zero value.
func (Instance) AsRefCounted ¶
func (self Instance) AsRefCounted() [1]gd.RefCounted
func (Instance) AsResource ¶
func (Instance) AsVisualShaderNode ¶
func (self Instance) AsVisualShaderNode() VisualShaderNode.Instance
func (Instance) AsVisualShaderNodeColorOp ¶
func (Instance) SetOperator ¶
type Operator ¶
type Operator int //gd:VisualShaderNodeColorOp.Operator
const ( /*Produce a screen effect with the following formula: [codeblock] result = vec3(1.0) - (vec3(1.0) - a) * (vec3(1.0) - b); [/codeblock]*/ OpScreen Operator = 0 /*Produce a difference effect with the following formula: [codeblock] result = abs(a - b); [/codeblock]*/ OpDifference Operator = 1 /*Produce a darken effect with the following formula: [codeblock] result = min(a, b); [/codeblock]*/ OpDarken Operator = 2 /*Produce a lighten effect with the following formula: [codeblock] result = max(a, b); [/codeblock]*/ OpLighten Operator = 3 /*Produce an overlay effect with the following formula: [codeblock] for (int i = 0; i < 3; i++) { float base = a[i]; float blend = b[i]; if (base < 0.5) { result[i] = 2.0 * base * blend; } else { result[i] = 1.0 - 2.0 * (1.0 - blend) * (1.0 - base); } } [/codeblock]*/ OpOverlay Operator = 4 /*Produce a dodge effect with the following formula: [codeblock] result = a / (vec3(1.0) - b); [/codeblock]*/ OpDodge Operator = 5 /*Produce a burn effect with the following formula: [codeblock] result = vec3(1.0) - (vec3(1.0) - a) / b; [/codeblock]*/ OpBurn Operator = 6 /*Produce a soft light effect with the following formula: [codeblock] for (int i = 0; i < 3; i++) { float base = a[i]; float blend = b[i]; if (base < 0.5) { result[i] = base * (blend + 0.5); } else { result[i] = 1.0 - (1.0 - base) * (1.0 - (blend - 0.5)); } } [/codeblock]*/ OpSoftLight Operator = 7 /*Produce a hard light effect with the following formula: [codeblock] for (int i = 0; i < 3; i++) { float base = a[i]; float blend = b[i]; if (base < 0.5) { result[i] = base * (2.0 * blend); } else { result[i] = 1.0 - (1.0 - base) * (1.0 - 2.0 * (blend - 0.5)); } } [/codeblock]*/ OpHardLight Operator = 8 /*Represents the size of the [enum Operator] enum.*/ OpMax Operator = 9 )