         self = inverse
     }
 
+    /// Returns an inverted version of the matrix if possible, or nil if not.
     public func inverted() -> AffineTransform? {
         let determinant = (m11 * m22) - (m12 * m21)
         if fabs(determinant.native) <= ε.native {


    private var affineTransform: AffineTransform

    public var transformStruct: NSAffineTransformStruct {
        get {
            return NSAffineTransformStruct(m11: affineTransform.m11,

        return true
    }
    
    /// Initializes an affine transform matrix using another transform object.
    public convenience init(transform: AffineTransform) {
        self.init()
        affineTransform = transform
    }

    /// Initializes an affine transform matrix to the identity matrix.
    public override init() {
        affineTransform = AffineTransform(
            m11: CGFloat(1.0), m12: CGFloat(),
