Uses of Record Class
cit244.api.image.SpriteDraw

Packages that use SpriteDraw
Package
Description
Main API for CIT AViz sketches, including drawing, input, timing, and controls.
Images, sprite regions, sprite sheets, and frame-based animation.
  • Uses of SpriteDraw in cit244.api

    Methods in cit244.api with parameters of type SpriteDraw
    Modifier and Type
    Method
    Description
    default void
    Graphics.sprite(SpriteDraw draw)
    Draws a sprite using its position, anchor, scale, rotation, flips, and optional tint.
  • Uses of SpriteDraw in cit244.api.image

    Methods in cit244.api.image that return SpriteDraw
    Modifier and Type
    Method
    Description
    SpriteDraw.anchor(double x, double y)
    Changes the anchor point, using fractions of the sprite's dimensions.
    Sprite.at(double x, double y)
    Creates drawing instructions with a top-left anchor and native scale.
    Sprite.at(Vec2 position)
    Creates drawing instructions at the given screen position.
    SpriteDraw.at(double x, double y)
    Returns drawing instructions at the given position.
    SpriteDraw.at(Vec2 position)
    Returns drawing instructions at the given position.
    SpriteDraw.bottomCenter()
    Sets the anchor to the center of the sprite's bottom edge.
    SpriteDraw.centered()
    Sets the anchor to the sprite's center.
    SpriteDraw.flipX()
    Enables horizontal mirroring.
    SpriteDraw.flipX(boolean enabled)
    Enables or disables horizontal mirroring.
    SpriteDraw.flipY()
    Enables vertical mirroring.
    SpriteDraw.flipY(boolean enabled)
    Enables or disables vertical mirroring.
    static SpriteDraw
    SpriteDraw.of(Sprite sprite, double x, double y)
    Creates drawing instructions at native scale with a top-left anchor, no rotation, no flipping, and no local tint.
    SpriteDraw.rotate(double radians)
    Sets clockwise rotation about the anchor.
    SpriteDraw.scale(double factor)
    Sets the uniform drawing scale.
    SpriteDraw.scaledBy(double factor)
    Multiplies the current scale by a factor.
    SpriteDraw.tint(Color color)
    Sets a local image tint, including alpha.
    SpriteDraw.translate(double dx, double dy)
    Moves the anchor by a displacement in screen coordinates, not along the sprite's rotated local axes.
    SpriteDraw.translate(Vec2 offset)
    Moves the anchor by a displacement in screen coordinates.