VisualShaderNodeColorOp

package
v0.0.0-...-7325ca5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 31, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Overview

Package VisualShaderNodeColorOp provides methods for working with VisualShaderNodeColorOp object instances.

Index

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 Any

type Any interface {
	gd.IsClass
	AsVisualShaderNodeColorOp() Instance
}

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 New

func New() Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) AsRefCounted

func (self Instance) AsRefCounted() [1]gd.RefCounted

func (Instance) AsResource

func (self Instance) AsResource() Resource.Instance

func (Instance) AsVisualShaderNode

func (self Instance) AsVisualShaderNode() VisualShaderNode.Instance

func (Instance) AsVisualShaderNodeColorOp

func (self Instance) AsVisualShaderNodeColorOp() Instance

func (Instance) Operator

func (Instance) SetOperator

func (self Instance) SetOperator(value gdclass.VisualShaderNodeColorOpOperator)

func (*Instance) UnsafePointer

func (self *Instance) UnsafePointer() unsafe.Pointer

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type Operator

type Operator = gdclass.VisualShaderNodeColorOpOperator //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
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL