Skip to content
On this page

kagurajs - v0.2.7 / Exports / ObjectContainer

Class: ObjectContainer

Hierarchy

  • Container

    ObjectContainer

    ↳↳ Sprite

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

new ObjectContainer()

Overrides

Container.constructor

Defined in

src/object/object-container/index.ts:17

Properties

_accessibleActive

Optional _accessibleActive: boolean

Inherited from

Container._accessibleActive

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:8


_accessibleDiv

Optional _accessibleDiv: IAccessibleHTMLElement

Inherited from

Container._accessibleDiv

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:9


_bounds

_bounds: Bounds

The bounds object, this is used to calculate and store the bounds of the displayObject.

Inherited from

Container._bounds

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:273


_boundsID

Protected _boundsID: number

Flags the cached bounds as dirty.

Inherited from

Container._boundsID

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:288


_boundsRect

Protected _boundsRect: Rectangle

Cache of this display-object's bounds-rectangle.

Inherited from

Container._boundsRect

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:290


_cacheAsBitmap

_cacheAsBitmap: boolean

Inherited from

Container._cacheAsBitmap

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:10


_cacheAsBitmapMultisample

_cacheAsBitmapMultisample: MSAA_QUALITY

Inherited from

Container._cacheAsBitmapMultisample

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:9


_cacheAsBitmapResolution

_cacheAsBitmapResolution: number

Inherited from

Container._cacheAsBitmapResolution

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:8


_cacheData

_cacheData: CacheData

Inherited from

Container._cacheData

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:11


_destroyed

Protected _destroyed: boolean

If the object has been destroyed via destroy(). If true, it should not be used.

Inherited from

Container._destroyed

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:294


_enabledFilters

Protected _enabledFilters: Filter[]

Currently enabled filters.

Inherited from

Container._enabledFilters

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:286


_height

Protected _height: number

Inherited from

Container._height

Defined in

node_modules/@pixi/display/lib/Container.d.ts:77


_internalEventMode

_internalEventMode: EventMode

Inherited from

Container._internalEventMode

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:37


_internalInteractive

_internalInteractive: boolean

Inherited from

Container._internalInteractive

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:34


_lastSortedIndex

Protected _lastSortedIndex: number

Which index in the children array the display component was before the previous zIndex sort. Used by containers to help sort objects with the same zIndex, by using previous array index as the decider.

Inherited from

Container._lastSortedIndex

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:266


_localBounds

_localBounds: Bounds

Local bounds object, swapped with _bounds when using getLocalBounds().

Inherited from

Container._localBounds

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:275


_localBoundsRect

Protected _localBoundsRect: Rectangle

Cache of this display-object's local-bounds rectangle.

Inherited from

Container._localBoundsRect

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:292


_mask

Protected _mask: Container<DisplayObject> | MaskData

The original, cached mask of the object.

Inherited from

Container._mask

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:271


_width

Protected _width: number

Inherited from

Container._width

Defined in

node_modules/@pixi/display/lib/Container.d.ts:76


_zIndex

Protected _zIndex: number

The zIndex of the displayObject. A higher value will mean it will be rendered on top of other displayObjects within the same container.

Inherited from

Container._zIndex

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:281


accessible

Optional accessible: boolean

Inherited from

Container.accessible

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:4


accessibleChildren

Optional accessibleChildren: boolean

Inherited from

Container.accessibleChildren

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:12


accessibleHint

Optional accessibleHint: string

Inherited from

Container.accessibleHint

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:6


accessiblePointerEvents

Optional accessiblePointerEvents: PointerEvents

Inherited from

Container.accessiblePointerEvents

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:11


accessibleTitle

Optional accessibleTitle: string

Inherited from

Container.accessibleTitle

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:5


accessibleType

Optional accessibleType: string

Inherited from

Container.accessibleType

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:10


alpha

alpha: number

The opacity of the object.

Inherited from

Container.alpha

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:217


cacheAsBitmap

cacheAsBitmap: boolean

Inherited from

Container.cacheAsBitmap

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:5


cacheAsBitmapMultisample

cacheAsBitmapMultisample: MSAA_QUALITY

Inherited from

Container.cacheAsBitmapMultisample

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:7


cacheAsBitmapResolution

cacheAsBitmapResolution: number

Inherited from

Container.cacheAsBitmapResolution

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:6


childContainer

Optional childContainer: {} | Container<DisplayObject>

Defined in

src/object/object-container/index.ts:16


children

Readonly children: DisplayObject[]

The array of children of this container.

Inherited from

Container.children

Defined in

node_modules/@pixi/display/lib/Container.d.ts:54


containerUpdateTransform

containerUpdateTransform: () => void

Type declaration

▸ (): void

Returns

void

Inherited from

Container.containerUpdateTransform

Defined in

node_modules/@pixi/display/lib/Container.d.ts:75


cullArea

cullArea: Rectangle

If set, this shape is used for culling instead of the bounds of this object. It can improve the culling performance of objects with many children. The culling area is defined in local space.

Inherited from

Container.cullArea

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:243


cullable

cullable: boolean

Should this object be rendered if the bounds of this object are out of frame?

Culling has no effect on whether updateTransform is called.

Inherited from

Container.cullable

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:237


cursor

cursor: string

The cursor preferred when the mouse pointer is hovering over.

Inherited from

Container.cursor

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:27


displayObjectUpdateTransform

displayObjectUpdateTransform: () => void

Type declaration

▸ (): void

Returns

void

Inherited from

Container.displayObjectUpdateTransform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:298


eventMode

eventMode: EventMode

The mode of interaction for this object

Inherited from

Container.eventMode

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:36


filterArea

filterArea: Rectangle

The area the filter is applied to. This is used as more of an optimization rather than figuring out the dimensions of the displayObject each frame you can set this rectangle.

Also works as an interaction mask.

Inherited from

Container.filterArea

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:250


filters

filters: null | Filter[]

Sets the filters for the displayObject. IMPORTANT: This is a WebGL only feature and will be ignored by the canvas renderer. To remove filters simply set this property to 'null'.

Inherited from

Container.filters

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:256


hitArea

hitArea: null | IHitArea

The hit-area specifies the area for which pointer events should be captured by this event target.

Inherited from

Container.hitArea

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:43


interactive

interactive: boolean

Whether this event target should fire UI events.

Inherited from

Container.interactive

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:33


interactiveChildren

interactiveChildren: boolean

Whether this event target has any children that need UI events. This can be used optimize event propagation.

Inherited from

Container.interactiveChildren

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:41


isInteractive

isInteractive: () => boolean

Type declaration

▸ (): boolean

Returns true if the DisplayObject has interactive 'static' or 'dynamic'

Returns

boolean

Inherited from

Container.isInteractive

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:39


isMask

isMask: boolean

Does any other displayObject use this object as a mask?

Inherited from

Container.isMask

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:260


isSprite

isSprite: boolean

Used to fast check if a sprite is.. a sprite!

Inherited from

Container.isSprite

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:258


name

name: null | string

Inherited from

Container.name

Defined in

node_modules/@pixi/mixin-get-child-by-name/global.d.ts:5


onclick

onclick: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'click' event

Inherited from

Container.onclick

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:47


onglobalmousemove

onglobalmousemove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'globalmousemove' event

Inherited from

Container.onglobalmousemove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:57


onglobalpointermove

onglobalpointermove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'globalpointermove' event

Inherited from

Container.onglobalpointermove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:77


onglobaltouchmove

onglobaltouchmove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'globaltouchmove' event

Inherited from

Container.onglobaltouchmove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:107


onmousedown

onmousedown: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mousedown' event

Inherited from

Container.onmousedown

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:49


onmouseenter

onmouseenter: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseenter' event

Inherited from

Container.onmouseenter

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:51


onmouseleave

onmouseleave: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseleave' event

Inherited from

Container.onmouseleave

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:53


onmousemove

onmousemove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mousemove' event

Inherited from

Container.onmousemove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:55


onmouseout

onmouseout: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseout' event

Inherited from

Container.onmouseout

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:59


onmouseover

onmouseover: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseover' event

Inherited from

Container.onmouseover

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:61


onmouseup

onmouseup: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseup' event

Inherited from

Container.onmouseup

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:63


onmouseupoutside

onmouseupoutside: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'mouseupoutside' event

Inherited from

Container.onmouseupoutside

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:65


onpointercancel

onpointercancel: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointercancel' event

Inherited from

Container.onpointercancel

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:67


onpointerdown

onpointerdown: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerdown' event

Inherited from

Container.onpointerdown

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:69


onpointerenter

onpointerenter: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerenter' event

Inherited from

Container.onpointerenter

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:71


onpointerleave

onpointerleave: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerleave' event

Inherited from

Container.onpointerleave

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:73


onpointermove

onpointermove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointermove' event

Inherited from

Container.onpointermove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:75


onpointerout

onpointerout: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerout' event

Inherited from

Container.onpointerout

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:79


onpointerover

onpointerover: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerover' event

Inherited from

Container.onpointerover

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:81


onpointertap

onpointertap: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointertap' event

Inherited from

Container.onpointertap

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:83


onpointerup

onpointerup: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerup' event

Inherited from

Container.onpointerup

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:85


onpointerupoutside

onpointerupoutside: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'pointerupoutside' event

Inherited from

Container.onpointerupoutside

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:87


onrightclick

onrightclick: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'rightclick' event

Inherited from

Container.onrightclick

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:89


onrightdown

onrightdown: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'rightdown' event

Inherited from

Container.onrightdown

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:91


onrightup

onrightup: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'rightup' event

Inherited from

Container.onrightup

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:93


onrightupoutside

onrightupoutside: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'rightupoutside' event

Inherited from

Container.onrightupoutside

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:95


ontap

ontap: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'tap' event

Inherited from

Container.ontap

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:97


ontouchcancel

ontouchcancel: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'touchcancel' event

Inherited from

Container.ontouchcancel

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:99


ontouchend

ontouchend: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'touchend' event

Inherited from

Container.ontouchend

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:101


ontouchendoutside

ontouchendoutside: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'touchendoutside' event

Inherited from

Container.ontouchendoutside

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:103


ontouchmove

ontouchmove: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'touchmove' event

Inherited from

Container.ontouchmove

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:105


ontouchstart

ontouchstart: null | FederatedEventHandler<FederatedPointerEvent>

Handler for 'touchstart' event

Inherited from

Container.ontouchstart

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:109


onwheel

onwheel: null | FederatedEventHandler<FederatedWheelEvent>

Handler for 'wheel' event

Inherited from

Container.onwheel

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:111


parent

parent: Container<DisplayObject>

Inherited from

Container.parent

Defined in

node_modules/@pixi/display/lib/Container.d.ts:74


renderId

Optional renderId: number

Inherited from

Container.renderId

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:13


renderable

renderable: boolean

Can this object be rendered, if false the object will not be drawn but the updateTransform methods will still be called.

Only affects recursive calls from parent. You can ask for bounds manually.

Inherited from

Container.renderable

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:231


sortDirty

sortDirty: boolean

Should children be sorted by zIndex at the next updateTransform call.

Will get automatically set to true if a new child is added, or if a child's zIndex changes.

Inherited from

Container.sortDirty

Defined in

node_modules/@pixi/display/lib/Container.d.ts:73


sortableChildren

sortableChildren: boolean

If set to true, the container will sort its children by zIndex value when updateTransform() is called, or manually if sortChildren() is called.

This actually changes the order of elements in the array, so should be treated as a basic solution that is not performant compared to other solutions, such as PixiJS Layers

Also be aware of that this may not work nicely with the addChildAt() function, as the zIndex sorting may cause the child to automatically sorted to another position.

See

PIXI.Container.defaultSortableChildren

Inherited from

Container.sortableChildren

Defined in

node_modules/@pixi/display/lib/Container.d.ts:67


tabIndex

Optional tabIndex: number

Inherited from

Container.tabIndex

Defined in

node_modules/@pixi/accessibility/lib/accessibleTarget.d.ts:7


transform

transform: Transform

World transform and local transform of this object. This will become read-only later, please do not assign anything there unless you know what are you doing.

Inherited from

Container.transform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:215


visible

visible: boolean

The visibility of the object. If false the object will not be drawn, and the updateTransform function will not be called.

Only affects recursive calls from parent. You can ask for bounds or call updateTransform manually.

Inherited from

Container.visible

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:224


worldAlpha

Readonly worldAlpha: number

The multiplied alpha of the displayObject.

Inherited from

Container.worldAlpha

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:210


defaultSortableChildren

Static defaultSortableChildren: boolean

Sets the default value for the container property sortableChildren. If set to true, the container will sort its children by zIndex value when updateTransform() is called, or manually if sortChildren() is called.

This actually changes the order of elements in the array, so should be treated as a basic solution that is not performant compared to other solutions, such as PixiJS Layers.

Also be aware of that this may not work nicely with the addChildAt() function, as the zIndex sorting may cause the child to automatically sorted to another position.

Static

Inherited from

Container.defaultSortableChildren

Defined in

node_modules/@pixi/display/lib/Container.d.ts:49


prefixed

Static prefixed: string | boolean

Inherited from

Container.prefixed

Defined in

node_modules/eventemitter3/index.d.ts:9

Accessors

_tempDisplayObjectParent

get _tempDisplayObjectParent(): TemporaryDisplayObject

Returns

TemporaryDisplayObject

Member

Inherited from

Container._tempDisplayObjectParent

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:431


angle

get angle(): number

The angle of the object in degrees. 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.

Returns

number

Inherited from

Container.angle

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:509

set angle(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.angle

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:510


destroyed

get destroyed(): boolean

Readonly flag for destroyed display objects.

Returns

boolean

Inherited from

Container.destroyed

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:324


height

get height(): number

The height of the Container, setting this will actually modify the scale to achieve the value set.

Returns

number

Inherited from

Container.height

Defined in

node_modules/@pixi/display/lib/Container.d.ts:229

set height(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.height

Defined in

node_modules/@pixi/display/lib/Container.d.ts:230


localTransform

get localTransform(): Matrix

Current transform of the object based on local factors: position, scale, other stuff.

Returns

Matrix

Inherited from

Container.localTransform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:469


mask

get mask(): null | Container<DisplayObject> | MaskData

Sets a mask for the displayObject. A mask is an object that limits the visibility of an object to the shape of the mask applied to it. In PixiJS a regular mask must be a PIXI.Graphics or a PIXI.Sprite object. This allows for much faster masking in canvas as it utilities shape clipping. Furthermore, a mask of an object must be in the subtree of its parent. Otherwise, getLocalBounds may calculate incorrect bounds, which makes the container's width and height wrong. To remove a mask, set this property to null.

For sprite mask both alpha and red channel are used. Black mask is the same as transparent mask.

Returns

null | Container<DisplayObject> | MaskData

Example

ts
import { Graphics, Sprite } from 'pixi.js';

const graphics = new Graphics();
graphics.beginFill(0xFF3300);
graphics.drawRect(50, 250, 100, 100);
graphics.endFill();

const sprite = new Sprite(texture);
sprite.mask = graphics;

Todo

At the moment, CanvasRenderer doesn't support Sprite as mask.

Inherited from

Container.mask

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:547

set mask(value): void

Parameters

NameType
valuenull | Container<DisplayObject> | MaskData

Returns

void

Inherited from

Container.mask

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:548


pivot

get pivot(): ObservablePoint<any>

The center of rotation, scaling, and skewing for this display object in its local space. The position is the projection of pivot in the parent's local space.

By default, the pivot is the origin (0, 0).

Returns

ObservablePoint<any>

Since

4.0.0

Inherited from

Container.pivot

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:491

set pivot(value): void

Parameters

NameType
valueIPointData

Returns

void

Inherited from

Container.pivot

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:492


position

get position(): ObservablePoint<any>

The coordinate of the object relative to the local coordinates of the parent.

Returns

ObservablePoint<any>

Since

4.0.0

Inherited from

Container.position

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:474

set position(value): void

Parameters

NameType
valueIPointData

Returns

void

Inherited from

Container.position

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:475


rotation

get rotation(): number

The rotation of the object in radians. 'rotation' and 'angle' have the same effect on a display object; rotation is in radians, angle is in degrees.

Returns

number

Inherited from

Container.rotation

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:503

set rotation(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.rotation

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:504


scale

get scale(): ObservablePoint<any>

The scale factors of this object along the local coordinate axes.

The default scale is (1, 1).

Returns

ObservablePoint<any>

Since

4.0.0

Inherited from

Container.scale

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:482

set scale(value): void

Parameters

NameType
valueIPointData

Returns

void

Inherited from

Container.scale

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:483


skew

get skew(): ObservablePoint<any>

The skew factor for the object in radians.

Returns

ObservablePoint<any>

Since

4.0.0

Inherited from

Container.skew

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:497

set skew(value): void

Parameters

NameType
valueIPointData

Returns

void

Inherited from

Container.skew

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:498


width

get width(): number

The width of the Container, setting this will actually modify the scale to achieve the value set.

Returns

number

Inherited from

Container.width

Defined in

node_modules/@pixi/display/lib/Container.d.ts:226

set width(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.width

Defined in

node_modules/@pixi/display/lib/Container.d.ts:227


worldTransform

get worldTransform(): Matrix

Current transform of the object based on world (parent) factors.

Returns

Matrix

Inherited from

Container.worldTransform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:464


worldVisible

get worldVisible(): boolean

Indicates if the object is globally visible.

Returns

boolean

Inherited from

Container.worldVisible

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:525


x

get x(): number

The position of the displayObject on the x axis relative to the local coordinates of the parent. An alias to position.x

Returns

number

Inherited from

Container.x

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:452

set x(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.x

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:453


y

get y(): number

The position of the displayObject on the y axis relative to the local coordinates of the parent. An alias to position.y

Returns

number

Inherited from

Container.y

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:458

set y(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.y

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:459


zIndex

get zIndex(): number

The zIndex of the displayObject.

If a container has the sortableChildren property set to true, children will be automatically sorted by zIndex value; a higher value will mean it will be moved towards the end of the array, and thus rendered on top of other display objects within the same container.

Returns

number

See

PIXI.Container#sortableChildren

Inherited from

Container.zIndex

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:519

set zIndex(value): void

Parameters

NameType
valuenumber

Returns

void

Inherited from

Container.zIndex

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:520

Methods

_cacheAsBitmapDestroy

_cacheAsBitmapDestroy(options?): void

Parameters

NameType
options?boolean | IDestroyOptions

Returns

void

Inherited from

Container._cacheAsBitmapDestroy

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:19


_calculateBounds

Protected _calculateBounds(): void

Recalculates the content bounds of this object. This should be overriden to calculate the bounds of this specific object (not including children).

Returns

void

Inherited from

Container._calculateBounds

Defined in

node_modules/@pixi/display/lib/Container.d.ts:170


_calculateCachedBounds

_calculateCachedBounds(): void

Returns

void

Inherited from

Container._calculateCachedBounds

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:14


_destroyCachedDisplayObject

_destroyCachedDisplayObject(): void

Returns

void

Inherited from

Container._destroyCachedDisplayObject

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:18


_getCachedLocalBounds

_getCachedLocalBounds(): Rectangle

Returns

Rectangle

Inherited from

Container._getCachedLocalBounds

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:15


_initCachedDisplayObject

_initCachedDisplayObject(renderer): void

Parameters

NameType
rendererRenderer

Returns

void

Inherited from

Container._initCachedDisplayObject

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:13


_initCachedDisplayObjectCanvas

_initCachedDisplayObjectCanvas(renderer): void

Parameters

NameType
rendererIRenderer<ICanvas>

Returns

void

Inherited from

Container._initCachedDisplayObjectCanvas

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:17


_recursivePostUpdateTransform

Protected _recursivePostUpdateTransform(): void

Recursively updates transform of all objects from the root to this one internal function for toLocal()

Returns

void

Inherited from

Container._recursivePostUpdateTransform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:334


_render

Protected _render(_renderer): void

To be overridden by the subclasses.

Parameters

NameTypeDescription
_rendererRendererThe renderer

Returns

void

Inherited from

Container._render

Defined in

node_modules/@pixi/display/lib/Container.d.ts:211


_renderCached

_renderCached(renderer): void

Parameters

NameType
rendererRenderer

Returns

void

Inherited from

Container._renderCached

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:12


_renderCachedCanvas

_renderCachedCanvas(renderer): void

Parameters

NameType
rendererIRenderer<ICanvas>

Returns

void

Inherited from

Container._renderCachedCanvas

Defined in

node_modules/@pixi/mixin-cache-as-bitmap/global.d.ts:16


_renderWithCulling

Protected _renderWithCulling(renderer): void

Renders this object and its children with culling.

Parameters

NameTypeDescription
rendererRendererThe renderer

Returns

void

Inherited from

Container._renderWithCulling

Defined in

node_modules/@pixi/display/lib/Container.d.ts:176


addChild

addChild<U>(...children): U[0]

Adds one or more children to the container.

Multiple items can be added like so: myContainer.addChild(thingOne, thingTwo, thingThree)

Type parameters

NameType
Uextends DisplayObject[]

Parameters

NameTypeDescription
...childrenUThe DisplayObject(s) to add to the container

Returns

U[0]

  • The first child that was added.

Inherited from

Container.addChild

Defined in

node_modules/@pixi/display/lib/Container.d.ts:91


addChildAt

addChildAt<U>(child, index): U

Adds a child to the container at a specified index. If the index is out of bounds an error will be thrown. If the child is already in this container, it will be moved to the specified index.

Type parameters

NameType
Uextends DisplayObject<U>

Parameters

NameTypeDescription
childUThe child to add.
indexnumberThe absolute index where the child will be positioned at the end of the operation.

Returns

U

The child that was added.

Inherited from

Container.addChildAt

Defined in

node_modules/@pixi/display/lib/Container.d.ts:99


addEventListener

addEventListener<K>(type, listener, options?): void

Type parameters

NameType
Kextends keyof FederatedEventMap | keyof GlobalFederatedEventMap

Parameters

NameType
typeK
listener(e: AllFederatedEventMap[K]) => any
options?AddListenerOptions

Returns

void

Inherited from

Container.addEventListener

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:116

addEventListener(type, listener, options?): void

Parameters

NameType
typestring
listenerEventListenerOrEventListenerObject
options?AddListenerOptions

Returns

void

Inherited from

Container.addEventListener

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:117


addListener

addListener<T>(event, fn, context?): ObjectContainer

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
fn(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void
context?any

Returns

ObjectContainer

Inherited from

Container.addListener

Defined in

node_modules/eventemitter3/index.d.ts:45


calculateBounds

calculateBounds(): void

Recalculates the bounds of the container.

This implementation will automatically fit the children's bounds into the calculation. Each child's bounds is limited to its mask's bounds or filterArea, if any is applied.

Returns

void

Inherited from

Container.calculateBounds

Defined in

node_modules/@pixi/display/lib/Container.d.ts:153


destroy

destroy(options?): void

Removes all internal references and listeners as well as removes children from the display list. Do not use a Container after calling destroy.

Parameters

NameTypeDescription
options?boolean | IDestroyOptionsOptions parameter. A boolean will act as if all options have been set to that value

Returns

void

Inherited from

Container.destroy

Defined in

node_modules/@pixi/display/lib/Container.d.ts:224


disableTempParent

disableTempParent(cacheParent): void

Pair method for enableTempParent

Parameters

NameTypeDescription
cacheParentContainer<DisplayObject>Actual parent of element

Returns

void

Inherited from

Container.disableTempParent

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:447


dispatchEvent

dispatchEvent(event): boolean

Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise.

Parameters

NameType
eventEvent

Returns

boolean

Inherited from

Container.dispatchEvent

Defined in

node_modules/typescript/lib/lib.dom.d.ts:5309


emit

emit<T>(event, ...args): boolean

Calls each of the listeners registered for a given event.

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
...argsArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]

Returns

boolean

Inherited from

Container.emit

Defined in

node_modules/eventemitter3/index.d.ts:32


enableTempParent

enableTempParent(): Container<DisplayObject>

Used in Renderer, cacheAsBitmap and other places where you call an updateTransform on root.

js
const cacheParent = elem.enableTempParent();
elem.updateTransform();
elem.disableTempParent(cacheParent);

Returns

Container<DisplayObject>

  • Current parent

Inherited from

Container.enableTempParent

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:442


eventNames

eventNames(): keyof DisplayObjectEvents[]

Return an array listing the events for which the emitter has registered listeners.

Returns

keyof DisplayObjectEvents[]

Inherited from

Container.eventNames

Defined in

node_modules/eventemitter3/index.d.ts:15


from

from(childContainer): void

Parameters

NameType
childContainerContainer<DisplayObject>

Returns

void

Defined in

src/object/object-container/index.ts:23


getBounds

getBounds(skipUpdate?, rect?): Rectangle

Calculates and returns the (world) bounds of the display object as a [Rectangle]PIXI.Rectangle.

This method is expensive on containers with a large subtree (like the stage). This is because the bounds of a container depend on its children's bounds, which recursively causes all bounds in the subtree to be recalculated. The upside, however, is that calling getBounds once on a container will indeed update the bounds of all children (the whole subtree, in fact). This side effect should be exploited by using displayObject._bounds.getRectangle() when traversing through all the bounds in a scene graph. Otherwise, calling getBounds on each object in a subtree will cause the total cost to increase quadratically as its height increases.

The transforms of all objects in a container's subtree and of all ancestors are updated. The world bounds of all display objects in a container's subtree will also be recalculated.

The _bounds object stores the last calculation of the bounds. You can use to entirely skip bounds calculation if needed.

js
const lastCalculatedBounds = displayObject._bounds.getRectangle(optionalRect);

Do know that usage of getLocalBounds can corrupt the _bounds of children (the whole subtree, actually). This is a known issue that has not been solved. See [getLocalBounds]PIXI.DisplayObject#getLocalBounds for more details.

getBounds should be called with skipUpdate equal to true in a render() call. This is because the transforms are guaranteed to be update-to-date. In fact, recalculating inside a render() call may cause corruption in certain cases.

Parameters

NameTypeDescription
skipUpdate?booleanSetting to true will stop the transforms of the scene graph from being updated. This means the calculation returned MAY be out of date BUT will give you a nice performance boost.
rect?RectangleOptional rectangle to store the result of the bounds calculation.

Returns

Rectangle

  • The minimum axis-aligned rectangle in world space that fits around this object.

Inherited from

Container.getBounds

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:371


getChildAt

getChildAt(index): DisplayObject

Returns the child at the specified index

Parameters

NameTypeDescription
indexnumberThe index to get the child at

Returns

DisplayObject

  • The child at the given index, if any.

Inherited from

Container.getChildAt

Defined in

node_modules/@pixi/display/lib/Container.d.ts:123


getChildByName

getChildByName<T>(name, deep?): null | T

Type parameters

NameType
Textends DisplayObject<T> = DisplayObject

Parameters

NameType
namestring
deep?boolean

Returns

null | T

Inherited from

Container.getChildByName

Defined in

node_modules/@pixi/mixin-get-child-by-name/global.d.ts:10


getChildIndex

getChildIndex(child): number

Returns the index position of a child DisplayObject instance

Parameters

NameTypeDescription
childDisplayObjectThe DisplayObject instance to identify

Returns

number

  • The index position of the child display object to identify

Inherited from

Container.getChildIndex

Defined in

node_modules/@pixi/display/lib/Container.d.ts:111


getGlobalPosition

getGlobalPosition(point?, skipUpdate?): Point

Parameters

NameType
point?Point
skipUpdate?boolean

Returns

Point

Inherited from

Container.getGlobalPosition

Defined in

node_modules/@pixi/mixin-get-global-position/global.d.ts:5


getLocalBounds

getLocalBounds(rect?, skipChildrenUpdate?): Rectangle

Retrieves the local bounds of the displayObject as a rectangle object.

Calling getLocalBounds may invalidate the _bounds of the whole subtree below. If using it inside a render() call, it is advised to call getBounds() immediately after to recalculate the world bounds of the subtree.

Parameters

NameTypeDescription
rect?RectangleOptional rectangle to store the result of the bounds calculation.
skipChildrenUpdate?booleanSetting to true will stop re-calculation of children transforms, it was default behaviour of pixi 4.0-5.2 and caused many problems to users.

Returns

Rectangle

  • The rectangular bounding area.

Inherited from

Container.getLocalBounds

Defined in

node_modules/@pixi/display/lib/Container.d.ts:164


listenerCount

listenerCount(event): number

Return the number of listeners listening to a given event.

Parameters

NameType
eventkeyof DisplayObjectEvents

Returns

number

Inherited from

Container.listenerCount

Defined in

node_modules/eventemitter3/index.d.ts:27


listeners

listeners<T>(event): (...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void[]

Return the listeners registered for a given event.

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT

Returns

(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void[]

Inherited from

Container.listeners

Defined in

node_modules/eventemitter3/index.d.ts:20


off

off<T>(event, fn?, context?, once?): ObjectContainer

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
fn?(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void
context?any
once?boolean

Returns

ObjectContainer

Inherited from

Container.off

Defined in

node_modules/eventemitter3/index.d.ts:69


on

on<T>(event, fn, context?): ObjectContainer

Add a listener for a given event.

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
fn(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void
context?any

Returns

ObjectContainer

Inherited from

Container.on

Defined in

node_modules/eventemitter3/index.d.ts:40


onChildrenChange

Protected onChildrenChange(_length?): void

Overridable method that can be used by Container subclasses whenever the children array is modified.

Parameters

NameType
_length?number

Returns

void

Inherited from

Container.onChildrenChange

Defined in

node_modules/@pixi/display/lib/Container.d.ts:83


once

once<T>(event, fn, context?): ObjectContainer

Add a one-time listener for a given event.

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
fn(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void
context?any

Returns

ObjectContainer

Inherited from

Container.once

Defined in

node_modules/eventemitter3/index.d.ts:54


removeAllListeners

removeAllListeners(event?): ObjectContainer

Remove all listeners, or those of the specified event.

Parameters

NameType
event?keyof DisplayObjectEvents

Returns

ObjectContainer

Inherited from

Container.removeAllListeners

Defined in

node_modules/eventemitter3/index.d.ts:79


removeChild

removeChild<U>(...children): U[0]

Removes one or more children from the container.

Type parameters

NameType
Uextends DisplayObject[]

Parameters

NameTypeDescription
...childrenUThe DisplayObject(s) to remove

Returns

U[0]

The first child that was removed.

Inherited from

Container.removeChild

Defined in

node_modules/@pixi/display/lib/Container.d.ts:129


removeChildAt

removeChildAt(index): DisplayObject

Removes a child from the specified index position.

Parameters

NameTypeDescription
indexnumberThe index to get the child from

Returns

DisplayObject

The child that was removed.

Inherited from

Container.removeChildAt

Defined in

node_modules/@pixi/display/lib/Container.d.ts:135


removeChildren

removeChildren(beginIndex?, endIndex?): DisplayObject[]

Removes all children from this container that are within the begin and end indexes.

Parameters

NameTypeDescription
beginIndex?numberThe beginning position.
endIndex?numberThe ending position. Default value is size of the container.

Returns

DisplayObject[]

  • List of removed children

Inherited from

Container.removeChildren

Defined in

node_modules/@pixi/display/lib/Container.d.ts:142


removeEventListener

removeEventListener<K>(type, listener, options?): void

Type parameters

NameType
Kextends keyof FederatedEventMap | keyof GlobalFederatedEventMap

Parameters

NameType
typeK
listener(e: AllFederatedEventMap[K]) => any
options?RemoveListenerOptions

Returns

void

Inherited from

Container.removeEventListener

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:118

removeEventListener(type, listener, options?): void

Parameters

NameType
typestring
listenerEventListenerOrEventListenerObject
options?RemoveListenerOptions

Returns

void

Inherited from

Container.removeEventListener

Defined in

node_modules/@pixi/events/lib/FederatedEventTarget.d.ts:119


removeFromParent

removeFromParent(): void

Remove the DisplayObject from its parent Container. If the DisplayObject has no parent, do nothing.

Returns

void

Inherited from

Container.removeFromParent

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:404


removeListener

removeListener<T>(event, fn?, context?, once?): ObjectContainer

Remove the listeners of a given event.

Type parameters

NameType
Textends keyof DisplayObjectEvents

Parameters

NameType
eventT
fn?(...args: ArgumentMap<DisplayObjectEvents>[Extract<T, keyof DisplayObjectEvents>]) => void
context?any
once?boolean

Returns

ObjectContainer

Inherited from

Container.removeListener

Defined in

node_modules/eventemitter3/index.d.ts:63


render

render(renderer): void

Renders the object using the WebGL renderer.

The [_render]PIXI.Container#_render method is be overriden for rendering the contents of the container itself. This render method will invoke it, and also invoke the render methods of all children afterward.

If renderable or visible is false or if worldAlpha is not positive or if cullable is true and the bounds of this object are out of frame, this implementation will entirely skip rendering. See PIXI.DisplayObject for choosing between renderable or visible. Generally, setting alpha to zero is not recommended for purely skipping rendering.

When your scene becomes large (especially when it is larger than can be viewed in a single screen), it is advised to employ culling to automatically skip rendering objects outside of the current screen. See [cullable]PIXI.DisplayObject#cullable and [cullArea]PIXI.DisplayObject#cullArea. Other culling methods might be better suited for a large number static objects; see [@pixi-essentials/cull]https://www.npmjs.com/package/@pixi-essentials/cull and [pixi-cull]https://www.npmjs.com/package/pixi-cull.

The [renderAdvanced]PIXI.Container#renderAdvanced method is internally used when when masking or filtering is applied on a container. This does, however, break batching and can affect performance when masking and filtering is applied extensively throughout the scene graph.

Parameters

NameTypeDescription
rendererRendererThe renderer

Returns

void

Inherited from

Container.render

Defined in

node_modules/@pixi/display/lib/Container.d.ts:201


renderAdvanced

Protected renderAdvanced(renderer): void

Render the object using the WebGL renderer and advanced features.

Parameters

NameTypeDescription
rendererRendererThe renderer

Returns

void

Inherited from

Container.renderAdvanced

Defined in

node_modules/@pixi/display/lib/Container.d.ts:206


setChildIndex

setChildIndex(child, index): void

Changes the position of an existing child in the display object container

Parameters

NameTypeDescription
childDisplayObjectThe child DisplayObject instance for which you want to change the index number
indexnumberThe resulting index number for the child display object

Returns

void

Inherited from

Container.setChildIndex

Defined in

node_modules/@pixi/display/lib/Container.d.ts:117


setParent

setParent(container): Container<DisplayObject>

Set the parent Container of this DisplayObject.

Parameters

NameTypeDescription
containerContainer<DisplayObject>The Container to add this DisplayObject to.

Returns

Container<DisplayObject>

  • The Container that this DisplayObject was added to.

Inherited from

Container.setParent

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:402


setTransform

setTransform(x?, y?, scaleX?, scaleY?, rotation?, skewX?, skewY?, pivotX?, pivotY?): ObjectContainer

Convenience function to set the position, scale, skew and pivot at once.

Parameters

NameTypeDescription
x?numberThe X position
y?numberThe Y position
scaleX?numberThe X scale value
scaleY?numberThe Y scale value
rotation?numberThe rotation
skewX?numberThe X skew value
skewY?numberThe Y skew value
pivotX?numberThe X pivot value
pivotY?numberThe Y pivot value

Returns

ObjectContainer

  • The DisplayObject instance

Inherited from

Container.setTransform

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:418


sortChildren

sortChildren(): void

Sorts children by zIndex. Previous order is maintained for 2 children with the same zIndex.

Returns

void

Inherited from

Container.sortChildren

Defined in

node_modules/@pixi/display/lib/Container.d.ts:144


swapChildren

swapChildren(child, child2): void

Swaps the position of 2 Display Objects within this container.

Parameters

NameTypeDescription
childDisplayObjectFirst display object to swap
child2DisplayObjectSecond display object to swap

Returns

void

Inherited from

Container.swapChildren

Defined in

node_modules/@pixi/display/lib/Container.d.ts:105


toGlobal

toGlobal<P>(position, point?, skipUpdate?): P

Calculates the global position of the display object.

Type parameters

NameType
Pextends IPointData = Point

Parameters

NameTypeDescription
positionIPointDataThe world origin to calculate from.
point?PA Point object in which to store the value, optional (otherwise will create a new Point).
skipUpdate?booleanShould we skip the update transform.

Returns

P

  • A point object representing the position of this object.

Inherited from

Container.toGlobal

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:386


toLocal

toLocal<P>(position, from?, point?, skipUpdate?): P

Calculates the local position of the display object relative to another point.

Type parameters

NameType
Pextends IPointData = Point

Parameters

NameTypeDescription
positionIPointDataThe world origin to calculate from.
from?DisplayObjectThe DisplayObject to calculate the global position from.
point?PA Point object in which to store the value, optional (otherwise will create a new Point).
skipUpdate?booleanShould we skip the update transform

Returns

P

  • A point object representing the position of this object

Inherited from

Container.toLocal

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:396


updateTransform

updateTransform(): void

Updates the transform on all children of this container for rendering.

Returns

void

Inherited from

Container.updateTransform

Defined in

node_modules/@pixi/display/lib/Container.d.ts:146


mixin

Static mixin(source): void

Mixes all enumerable properties and methods from a source object to DisplayObject.

Parameters

NameTypeDescription
sourceDict<any>The source of properties and methods to mix in.

Returns

void

Inherited from

Container.mixin

Defined in

node_modules/@pixi/display/lib/DisplayObject.d.ts:303