VisualShaderNodeDerivativeFunc

package
v0.0.0-...-fa94a0d Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2025 License: MIT Imports: 25 Imported by: 0

Documentation

Overview

This node is only available in Fragment and Light visual shaders.

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
	AsVisualShaderNodeDerivativeFunc() Instance
}

type Extension

type Extension[T gdclass.Interface] struct{ gdclass.Extension[T, Instance] }

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]) AsObject

func (self *Extension[T]) AsObject() [1]gd.Object

func (*Extension[T]) AsRefCounted

func (self *Extension[T]) AsRefCounted() [1]gd.RefCounted

func (*Extension[T]) AsResource

func (self *Extension[T]) AsResource() Resource.Instance

func (*Extension[T]) AsVisualShaderNode

func (self *Extension[T]) AsVisualShaderNode() VisualShaderNode.Instance

func (*Extension[T]) AsVisualShaderNodeDerivativeFunc

func (self *Extension[T]) AsVisualShaderNodeDerivativeFunc() Instance

type Function

type Function int //gd:VisualShaderNodeDerivativeFunc.Function
const (
	// Sum of absolute derivative in x and y.
	FuncSum Function = 0
	// Derivative in x using local differencing.
	FuncX Function = 1
	// Derivative in y using local differencing.
	FuncY Function = 2
	// Represents the size of the [Function] enum.
	FuncMax Function = 3
)

type ID

type ID Object.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.

func (ID) Instance

func (id ID) Instance() (Instance, bool)

type Instance

Instance of the class with convieniently typed arguments and results.

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) AsVisualShaderNodeDerivativeFunc

func (self Instance) AsVisualShaderNodeDerivativeFunc() Instance

func (Instance) Function

func (self Instance) Function() Function

func (Instance) ID

func (self Instance) ID() ID

func (Instance) OpType

func (self Instance) OpType() OpType

func (Instance) Precision

func (self Instance) Precision() Precision

func (Instance) SetFunction

func (self Instance) SetFunction(value Function)

func (*Instance) SetObject

func (self *Instance) SetObject(obj [1]gd.Object) bool

func (Instance) SetOpType

func (self Instance) SetOpType(value OpType)

func (Instance) SetPrecision

func (self Instance) SetPrecision(value Precision)

func (Instance) Virtual

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

type OpType

type OpType int //gd:VisualShaderNodeDerivativeFunc.OpType
const (
	// A floating-point scalar.
	OpTypeScalar OpType = 0
	// A 2D vector type.
	OpTypeVector2d OpType = 1
	// A 3D vector type.
	OpTypeVector3d OpType = 2
	// A 4D vector type.
	OpTypeVector4d OpType = 3
	// Represents the size of the [OpType] enum.
	OpTypeMax OpType = 4
)

type Precision

type Precision int //gd:VisualShaderNodeDerivativeFunc.Precision
const (
	// No precision is specified, the GPU driver is allowed to use whatever level of precision it chooses. This is the default option and is equivalent to using dFdx() or dFdy() in text shaders.
	PrecisionNone Precision = 0
	// The derivative will be calculated using the current fragment's neighbors (which may not include the current fragment). This tends to be faster than using [PrecisionFine], but may not be suitable when more precision is needed. This is equivalent to using dFdxCoarse() or dFdyCoarse() in text shaders.
	PrecisionCoarse Precision = 1
	// The derivative will be calculated using the current fragment and its immediate neighbors. This tends to be slower than using [PrecisionCoarse], but may be necessary when more precision is needed. This is equivalent to using dFdxFine() or dFdyFine() in text shaders.
	PrecisionFine Precision = 2
	// Represents the size of the [Precision] enum.
	PrecisionMax Precision = 3
)

Jump to

Keyboard shortcuts

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