Layer.from_visible


Description:

[ CCode ( has_construct_function = false ) ]
[ Version ( since = "2.6" ) ]
public Layer.from_visible (Image image, Image dest_image, string? name)

Create a new layer from what is visible in an image.

This procedure creates a new layer from what is visible in the given image.

The new layer still needs to be added to the image as this is not automatic. Add the new layer with the [method@Image.insert_layer] method.

Other attributes such as layer mask and offsets should be set with explicit procedure calls.

Parameters:

image

The source image from where the content is copied.

dest_image

The destination image to which to add the layer.

name

The layer name.

Returns:

The newly created layer.