text: (function (global) {
      "use strict";
  
      var __tempVec3 = vec3.create();
  
      var Transform = function () {
          var scope = this;
  
          var _matrix = mat4.create();
  
          scope.anchorPoint = {
              x:0,
              y:0
          };
  
          scope.position = {
              x:0,
              y:0
          };
  
          scope.rotationInRadians = 0;
  
          scope.scale = {
              x: 1,
              y: 1
          };
  
          scope.getMatrix = function() {
              return _matrix;
          };
  
          scope.recalculateMatrix = function() {
              // this takes the anchor point into consideration
              mat4.identity(_matrix);
              mat4.translate(_matrix, _matrix,
                  vec3.set(
                      __tempVec3,
                      scope.position.x,
                      scope.position.y,
                      0.0));
              mat4.rotateZ(_matrix, _matrix, scope.rotationInRadians);
              mat4.translate(_matrix, _matrix,
                  vec3.set(
                      __tempVec3,
                      -scope.anchorPoint.x,
                      -scope.anchorPoint.y,
                      0.0));
  
              mat4.scale(_matrix, _matrix,
                  vec3.set(
                      __tempVec3,
                      scope.scale.x,
                      scope.scale.y,
                      1.0));
  
              return _matrix;
          };
  
          return scope;
      };
  
      Transform.prototype = {
          constructor:Transform,
  
          clone: function() {
              var newTransform = new Transform();
              newTransform.copy(this);
              return newTransform;
          },
  
          copy: function(transform) {
              this.position.x = transform.position.x;
              this.position.y = transform.position.y;
              this.scale.x = transform.scale.x;
              this.scale.y = transform.scale.y;
              this.rotationInRadians = transform.rotationInRadians;
          }
      };
  
      // export
      global.Transform = Transform;
  })(this);