aboutsummaryrefslogtreecommitdiffstats
path: root/src/matrix.js
diff options
context:
space:
mode:
authorSaivan <savian@me.com>2018-04-18 20:55:06 +1000
committerSaivan <savian@me.com>2018-04-18 20:55:06 +1000
commit7a4979d0cfd4c4dbe91b53b69c62aa28c295af5c (patch)
tree55c8efb1dd5954544dc14702424388f26f31e1e1 /src/matrix.js
parentc37d94a4dccd3c0d2ce8db99bd80b6e514f5c7de (diff)
downloadsvg.js-7a4979d0cfd4c4dbe91b53b69c62aa28c295af5c.tar.gz
svg.js-7a4979d0cfd4c4dbe91b53b69c62aa28c295af5c.zip
Initial planning for the Timeline Module
This commit just includes a few plans and a massive derrangement of the fx module before it is to be refactored into the Timeline module. The basic methods are included, but everything is broken
Diffstat (limited to 'src/matrix.js')
-rw-r--r--src/matrix.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/matrix.js b/src/matrix.js
index 786d1c1..1649370 100644
--- a/src/matrix.js
+++ b/src/matrix.js
@@ -32,6 +32,13 @@ SVG.Matrix = SVG.invent({
// Transform a matrix into another matrix by manipulating the space
transform: function (o) {
+ // Check if o is a matrix and then left multiply it directly
+ if (o.a != null) {
+ var matrix = new SVG.Matrix(o)
+ var newMatrix = this.lmultiply(matrix)
+ return newMatrix
+ }
+
// Get all of the parameters required to form the matrix
var flipX = o.flip && (o.flip === 'x' || o.flip === 'both') ? -1 : 1
var flipY = o.flip && (o.flip === 'y' || o.flip === 'both') ? -1 : 1