Class: Gsk::ColorMatrixNode
- Inherits:
-
RenderNode
- Object
- RenderNode
- Gsk::ColorMatrixNode
- Defined in:
- (unknown)
Overview
A render node controlling the color matrix of its single child node.
Instance Method Summary collapse
-
#child ⇒ Gsk::RenderNode
Gets the child node that is getting its colors modified by the given node.
-
#color_matrix ⇒ Graphene::Matrix
Retrieves the color matrix used by the node.
-
#color_offset ⇒ Graphene::Vec4
Retrieves the color offset used by the node.
-
#initialize(child, color_matrix, color_offset) ⇒ Gsk::ColorMatrixNode
constructor
Creates a
GskRenderNodethat will drawn the child with color_matrix.
Methods inherited from RenderNode
deserialize, #draw, #get_bounds, #node_type, #ref, #serialize, #unref, #write_to_file
Constructor Details
#initialize(child, color_matrix, color_offset) ⇒ Gsk::ColorMatrixNode
Creates a GskRenderNode that will drawn the child with
color_matrix.
In particular, the node will transform colors by applying
pixel = transpose(color_matrix) * pixel + color_offset
for every pixel. The transformation operates on unpremultiplied colors, with color components ordered R, G, B, A.
Instance Method Details
#child ⇒ Gsk::RenderNode
Gets the child node that is getting its colors modified by the given node.
#color_matrix ⇒ Graphene::Matrix
Retrieves the color matrix used by the node.
#color_offset ⇒ Graphene::Vec4
Retrieves the color offset used by the node.