Package: gtk

Function gtk:snapshot-push-color-matrix

Lambda List

gtk:snapshot-push-color-matrix (snapshot matrix offset)

Arguments

snapshot -- a gtk:snapshot object
matrix -- a graphene:matrix-t instance for the color matrix to use
offset -- a graphene:vec4-t instance for the color offset to use

Details

Modifies the colors of an image by applying an affine transformation in RGB space. In particular, the colors will be transformed by applying
pixel = transpose(matrix) * pixel + offset  
for every pixel. The transformation operates on unpremultiplied colors, with color components ordered R, G, B, A.

The image is recorded until the next call to the gtk:snapshot-pop function.
 

See also

2025-2-12