Transform image

../../../../_images/image_transform.svg

Transforms and image into another shape

Algorithms:

  • crop

    Crops the image to the given rectanglular area

    x:

    Left edge of image

    y:

    Top edge of image

    width:

    Width of image

    height:

    Height of image

  • padding

    Adds a padding to an image

    x:

    If positive, amount of padding added on the left side. If negative the amount of padding added on the right side.

    y:

    If positive, amount of padding added on the top.If negative the amount of padding added on the bottom.

    k:

    Constant value used in padded areas

    add alpha:

    Adds an alpha with value 1.0 inside image, 0.0 outside

  • rescale

    Rescales an image by a given factor

    interpolation degree:

    Degree of polynomial (0 - 5) used for interpolation.

    0 - no interpolation, 1 - bi-linear interpolation, 3 - bi-cubic interpolation

    scale x:

    Scale factor along X direction (horizontal)

    scale y:

    Scale factor along Y direction (vertical)

  • resize

    Resizes an image to match the given dimensions

    width:

    The new width of the image

    height:

    The new height of the image

    padding:

    Adds padding to fill out full width/height after aspect-correct scaling

    aspect:

    Preserve aspect ratio (gives smaller size on one axis)

    interpolation degree:

    Degree of polynomial (0 - 5) used for interpolation.

    0 - no interpolation, 1 - bi-linear interpolation, 3 - bi-cubic interpolation

  • rotate

    Rotates an image

    angle:

    Angular degrees to rotate clockwise

    resize:

    If true new image dimensions are calculated to exactly fit the image

Input ports:

source : image

source image to filter
Output ports:

result : image

result after filtering
Configuration:
Algorithm (algorithm)
(no description)
angle (angle)
(no description)
scale y (scale y)
(no description)
scale x (scale x)
(no description)
k (k)
(no description)
height (height)
(no description)
padding (padding)
(no description)
width (width)
(no description)
aspect (aspect)
(no description)
y (y)
(no description)
x (x)
(no description)
interpolation degree (interpolation degree)
(no description)
add alpha (add alpha)
(no description)
resize (resize)
(no description)

Some of the docstrings for this module have been extracted from the scikit-image library and are covered by their respective licenses.

class node_transform.TransformFilter[source]