/// <summary> /// Computes the matrix for the given transformation. /// </summary> /// <returns>The transformation matrix representation.</returns> public TransformMatrix ComputeMatrix() { var dx = _x.ToPixel(); var dy = _y.ToPixel(); return(new TransformMatrix(1f, 0f, 0f, 0f, 1f, 0f, 0f, 0f, 1f, dx, dy, 0f)); }
public Single ToPixel() { var left = _left.ToPixel(); var right = _right.ToPixel(); switch (_op) { case '+': return(left + right); case '-': return(left - right); case '*': return(left * right); case '/': return(left / right); } return(0f); }
/// <summary> /// Computes the matrix for the given transformation. /// </summary> /// <returns>The transformation matrix representation.</returns> public TransformMatrix ComputeMatrix() { var dz = _z.ToPixel(); return(new TransformMatrix(1f, 0f, 0f, 0f, 1f, 0f, 0f, 0f, 1f, 0f, 0f, dz)); }