# Class: Live2DTransform (/jsdoc/pixi-vn-live2d/core/classes/Live2DTransform)



Defined in: node\_modules/untitled-pixi-live2d-engine/types/index.d.ts:4284

Useless class. May be useful in the future.

## Extends [#extends]

* `Transform`

## Constructors [#constructors]

### Constructor [#constructor]

\> **new Live2DTransform**(`options?`): `Live2DTransform`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:136

#### Parameters [#parameters]

##### options? [#options]

`TransformOptions`

Options for the transform.

#### Returns [#returns]

`Live2DTransform`

#### Inherited from [#inherited-from]

`Transform.constructor`

## Properties [#properties]

### \_cx [#_cx]

\> `protected&#x60; **\_cx**: `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:113

The X-coordinate value of the normalized local X axis,
the first column of the local transformation matrix without a scale.

#### Inherited from [#inherited-from-1]

`Transform._cx`

***

### \_cy [#_cy]

\> `protected&#x60; **\_cy**: `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:123

The X-coordinate value of the normalized local Y axis,
the second column of the local transformation matrix without a scale.

#### Inherited from [#inherited-from-2]

`Transform._cy`

***

### \_matrix [#_matrix]

\> **\_matrix**: `Matrix`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:55

**`Internal`**

The local transformation matrix.

#### Inherited from [#inherited-from-3]

`Transform._matrix`

***

### \_rotation [#_rotation]

\> `protected&#x60; **\_rotation**: `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:108

The rotation amount.

#### Inherited from [#inherited-from-4]

`Transform._rotation`

***

### \_sx [#_sx]

\> `protected&#x60; **\_sx**: `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:118

The Y-coordinate value of the normalized local X axis,
the first column of the local transformation matrix without a scale.

#### Inherited from [#inherited-from-5]

`Transform._sx`

***

### \_sy [#_sy]

\> `protected&#x60; **\_sy**: `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:128

The Y-coordinate value of the normalized local Y axis,
the second column of the local transformation matrix without a scale.

#### Inherited from [#inherited-from-6]

`Transform._sy`

***

### dirty [#dirty]

\> `protected` **dirty**: `boolean`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:129

#### Inherited from [#inherited-from-7]

`Transform.dirty`

***

### observer [#observer]

\> `protected` **observer**: `Observer`\<`Transform`>

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:130

#### Inherited from [#inherited-from-8]

`Transform.observer`

***

### pivot [#pivot]

\> **pivot**: `ObservablePoint`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:94

The pivot point of the container that it rotates around.

#### Example [#example]

```ts
// Center pivot
transform.pivot.set(sprite.width / 2, sprite.height / 2);

// Corner rotation
transform.pivot.set(0, 0);
transform.rotation = Math.PI / 4; // 45 degrees
```

#### Inherited from [#inherited-from-9]

`Transform.pivot`

***

### position [#position]

\> **position**: `ObservablePoint`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:68

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

#### Example [#example-1]

```ts
// Basic position setting
transform.position.set(100, 100);

// Individual coordinate access
transform.position.x = 50;
transform.position.y = 75;
```

#### Inherited from [#inherited-from-10]

`Transform.position`

***

### scale [#scale]

\> **scale**: `ObservablePoint`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:81

The scale factor of the object.

#### Example [#example-2]

```ts
// Uniform scaling
transform.scale.set(2, 2);

// Non-uniform scaling
transform.scale.x = 2; // Stretch horizontally
transform.scale.y = 0.5; // Compress vertically
```

#### Inherited from [#inherited-from-11]

`Transform.scale`

***

### skew [#skew]

\> **skew**: `ObservablePoint`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:106

The skew amount, on the x and y axis.

#### Example [#example-3]

```ts
// Apply horizontal skew
transform.skew.x = Math.PI / 6; // 30 degrees

// Apply both skews
transform.skew.set(Math.PI / 6, Math.PI / 8);
```

#### Inherited from [#inherited-from-12]

`Transform.skew`

## Accessors [#accessors]

### matrix [#matrix]

#### Get Signature [#get-signature]

\> **get** **matrix**(): `Matrix`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:150

The transformation matrix computed from the transform's properties.
Combines position, scale, rotation, skew, and pivot into a single matrix.

##### Example [#example-4]

```ts
// Get current matrix
const matrix = transform.matrix;
console.log(matrix.toString());
```

##### See [#see]

* Matrix For matrix operations
* [Transform.setFromMatrix](#setfrommatrix) For setting transform from matrix

##### Returns [#returns-1]

`Matrix`

#### Inherited from [#inherited-from-13]

`Transform.matrix`

***

### rotation [#rotation]

#### Get Signature [#get-signature-1]

\> **get** **rotation**(): `number`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:199

The rotation of the object in radians.

##### Example [#example-5]

```ts
// Basic rotation
transform.rotation = Math.PI / 4; // 45 degrees

// Rotate around pivot point
transform.pivot.set(50, 50);
transform.rotation = Math.PI; // 180 degrees around pivot

// Animate rotation
app.ticker.add(() => {
    transform.rotation += 0.1;
});
```

##### See [#see-1]

* [Transform#pivot](#pivot) For rotation point
* [Transform#skew](#skew) For skew effects

##### Returns [#returns-2]

`number`

#### Set Signature [#set-signature]

\> **set** **rotation**(`value`): `void`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:200

##### Parameters [#parameters-1]

###### value [#value]

`number`

##### Returns [#returns-3]

`void`

#### Inherited from [#inherited-from-14]

`Transform.rotation`

## Methods [#methods]

### \_onUpdate() [#_onupdate]

\> **\_onUpdate**(`point?`): `void`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:156

**`Internal`**

Called when a value changes.

#### Parameters [#parameters-2]

##### point? [#point]

`ObservablePoint`

#### Returns [#returns-4]

`void`

#### Inherited from [#inherited-from-15]

`Transform._onUpdate`

***

### setFromMatrix() [#setfrommatrix]

\> **setFromMatrix**(`matrix`): `void`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:179

Decomposes a matrix and sets the transforms properties based on it.

#### Parameters [#parameters-3]

##### matrix [#matrix-1]

`Matrix`

The matrix to decompose

#### Returns [#returns-5]

`void`

#### Example [#example-6]

```ts
// Basic matrix decomposition
const transform = new Transform();
const matrix = new Matrix()
    .translate(100, 100)
    .rotate(Math.PI / 4)
    .scale(2, 2);

transform.setFromMatrix(matrix);
console.log(transform.position.x); // 100
console.log(transform.rotation); // ~0.785 (π/4)
```

#### See [#see-2]

* Matrix#decompose For the decomposition logic
* [Transform#matrix](#matrix) For getting the current matrix

#### Inherited from [#inherited-from-16]

`Transform.setFromMatrix`

***

### toString() [#tostring]

\> **toString**(): `string`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:159

#### Returns [#returns-6]

`string`

#### Inherited from [#inherited-from-17]

`Transform.toString`

***

### updateSkew() [#updateskew]

\> `protected` **updateSkew**(): `void`

Defined in: node\_modules/pixi.js/lib/utils/misc/Transform.d.ts:158

Called when the skew or the rotation changes.

#### Returns [#returns-7]

`void`

#### Inherited from [#inherited-from-18]

`Transform.updateSkew`
