Texture Provider providing a cropped region of the input texture. The region is specified by the cropRect in local space and rotation. Can be accessed using Texture.control on a RectCropTexture asset, such as a Screen Crop Texture. For more information, see the Crop Textures guide.

// @input Asset.Texture screenCropTexture

// Zoom in
script.screenCropTexture.control.cropRect = Rect.create(-.5, .5, -.5, .5);

// Rotate by 90 degrees
script.screenCropTexture.control.rotation = Math.PI * .5;

Hierarchy (View Summary, Expand)

Constructors

Properties

cropRect: Rect

The cropped region to draw.

inputTexture: Texture

Input texture to crop.

rotation: number

Angle, in radians, the cropped region is rotated by.

Methods

  • Returns the texture's aspect ratio, which is calculated as width / height.

    Returns number

  • Returns true if the object matches or derives from the passed in type.

    Parameters

    • type: string

    Returns boolean

MMNEPVFCICPMFPCPTTAAATR