Interface: BoundsData
Defined in: node_modules/pixi.js/lib/scene/container/bounds/Bounds.d.ts:30
A simple axis-aligned bounding box (AABB) data structure used to define rectangular boundaries. Provides a clearer alternative to array-based bounds representation [minX, minY, maxX, maxY].
Example
// Create bounds data
const bounds: BoundsData = {
minX: 0,
minY: 0,
maxX: 100,
maxY: 100
};
// Calculate dimensions
const width = bounds.maxX - bounds.minX;
const height = bounds.maxY - bounds.minY;
// Check if point is inside
const isInside = (x: number, y: number) =>
x >= bounds.minX && x <= bounds.maxX &&
y >= bounds.minY && y <= bounds.maxY;
See
- Bounds For full bounds implementation
- Container#getBounds For getting bounds
Standard
Properties
maxX
> maxX: number
Defined in: node_modules/pixi.js/lib/scene/container/bounds/Bounds.d.ts:36
The maximum X coordinate of the bounds
maxY
> maxY: number
Defined in: node_modules/pixi.js/lib/scene/container/bounds/Bounds.d.ts:38
The maximum Y coordinate of the bounds
minX
> minX: number
Defined in: node_modules/pixi.js/lib/scene/container/bounds/Bounds.d.ts:32
The minimum X coordinate of the bounds
minY
> minY: number
Defined in: node_modules/pixi.js/lib/scene/container/bounds/Bounds.d.ts:34
The minimum Y coordinate of the bounds