← back to roto on ba3a.dev

AtlasRegion

data class AtlasRegion(val name: String, val index: Int, val x: Int, val y: Int, val width: Int, val height: Int, val origWidth: Int, val origHeight: Int, val offsetX: Int, val offsetY: Int)

One region of a libGDX atlas page: where its crop sits on the page and where that crop sits in the original frame.

Constructors

Link copied to clipboard
constructor(name: String, index: Int, x: Int, y: Int, width: Int, height: Int, origWidth: Int, origHeight: Int, offsetX: Int, offsetY: Int)

Properties

Link copied to clipboard
val height: Int

the crop's height

Link copied to clipboard
val index: Int

the region's index (-1 when the atlas gives none)

Link copied to clipboard

the region's name

Link copied to clipboard

the crop's left edge in the untrimmed frame

Link copied to clipboard

the gap between the crop's bottom edge and the untrimmed frame's bottom edge

Link copied to clipboard

the untrimmed frame's height

Link copied to clipboard

the untrimmed frame's width

Link copied to clipboard
val width: Int

the crop's width

Link copied to clipboard
val x: Int

the crop's left edge on the page, in pixels from the page's left

Link copied to clipboard
val y: Int

the crop's top edge on the page, in pixels from the page's top