Class ColorMatrixNode
java.lang.Object
org.javagi.base.ProxyInstance
org.gnome.gobject.TypeInstance
org.gnome.gsk.RenderNode
org.gnome.gsk.ColorMatrixNode
- All Implemented Interfaces:
Proxy
A render node controlling the color matrix of its single child node.
-
Nested Class Summary
Nested classes/interfaces inherited from class RenderNode
RenderNode.RenderNode$Impl -
Constructor Summary
ConstructorsConstructorDescriptionColorMatrixNode(MemorySegment address) Create a ColorMatrixNode instance for the provided memory address.ColorMatrixNode(RenderNode child, Matrix colorMatrix, Vec4 colorOffset) Creates aGskRenderNodethat will drawn thechildwithcolorMatrix. -
Method Summary
Modifier and TypeMethodDescriptionprotected ColorMatrixNodeasParent()Return this instance as if it were its parent type.getChild()Gets the child node that is getting its colors modified by the givennode.Retrieves the color matrix used by thenode.Retrieves the color offset used by thenode.static MemoryLayoutThe memory layout of the native struct.static @Nullable TypegetType()Get the GType of the ColorMatrixNode class.Methods inherited from class RenderNode
deserialize, draw, getBounds, getChildren, getNodeType, getOpaqueRect, ref, serialize, unref, writeToFileMethods inherited from class TypeInstance
callParent, callParent, cast, getPrivate, readGClass, writeGClassMethods inherited from class ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
ColorMatrixNode
Create a ColorMatrixNode instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
ColorMatrixNode
Creates a
GskRenderNodethat will drawn thechildwithcolorMatrix.In particular, the node will transform colors by applying
pixel = transpose(color_matrix) * pixel + color_offsetfor every pixel. The transformation operates on unpremultiplied colors, with color components ordered R, G, B, A.
- Parameters:
child- The node to drawcolorMatrix- The matrix to applycolorOffset- Values to add to the color
-
-
Method Details
-
getType
Get the GType of the ColorMatrixNode class.- Returns:
- the GType
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
asParent
Return this instance as if it were its parent type. Comparable to the Javasuperkeyword, but ensures the parent typeclass is also used in native code.- Overrides:
asParentin classRenderNode- Returns:
- the instance as if it were its parent type
-
getChild
Gets the child node that is getting its colors modified by the givennode.- Returns:
- The child that is getting its colors modified
-
getColorMatrix
Retrieves the color matrix used by thenode.- Returns:
- a 4x4 color matrix
-
getColorOffset
-