---
name: "SWF::Matrix"
section: "3pm"
platform: "linux"
package: "libswf-perl"
version: "1:0.4.4-1.1"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/SWF::Matrix"
---

# SWF::Matrix(3pm)

SWF matrix class

## NAME

SWF::Matrix - SWF matrix class

## SYNOPSIS

```
        use SWF::Matrix;
        $matrix = $displayItem->getMatrix();
        $scaleX = $matrix->getScaleX();
```

## DESCRIPTION

SWF::Matrix is a helper class useful for getting information about a display items's matrix. There is no constructor method, SWF::Matrix objects are available only thru SWF::DisplayItem's  *getMatrix()* method. The methods below give you read access to the six matrix elements.

## METHODS

- $scaleX = $matrix-\>*getScaleX()*

  Returns X scale.

- $scaleY = $matrix-\>*getScaleY()*

  Returns Y scale.

- $rot0 = $matrix-\>*getRotate0()*

  Returns rotation value 0.

- $rot1 = $matrix-\>*getRotate1()*

  Returns rotation value 1.

- $trX = $matrix-\>*getTranslateX()*

  Returns X translation value.

- $trY = $matrix-\>*getTranslateY()*

  Returns Y translation value.

## AUTHOR

```
        developers of
        ming.sourceforge.net
```

## SEE ALSO

SWF, SWF::DisplayItem
