Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
A structure specifying a transformation between user-space coordinates and device coordinates. The transformation is given by
programlisting x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0; y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0; /programlisting
- newtype Matrix = Matrix (ForeignPtr Matrix)
- newZeroMatrix :: MonadIO m => m Matrix
- noMatrix :: Maybe Matrix
- data MatrixConcatMethodInfo
- matrixConcat :: MonadIO m => Matrix -> Matrix -> m ()
- data MatrixCopyMethodInfo
- matrixCopy :: MonadIO m => Matrix -> m Matrix
- data MatrixFreeMethodInfo
- matrixFree :: MonadIO m => Matrix -> m ()
- data MatrixGetFontScaleFactorMethodInfo
- matrixGetFontScaleFactor :: MonadIO m => Matrix -> m Double
- data MatrixGetFontScaleFactorsMethodInfo
- matrixGetFontScaleFactors :: MonadIO m => Matrix -> m (Double, Double)
- data MatrixRotateMethodInfo
- matrixRotate :: MonadIO m => Matrix -> Double -> m ()
- data MatrixScaleMethodInfo
- matrixScale :: MonadIO m => Matrix -> Double -> Double -> m ()
- data MatrixTransformDistanceMethodInfo
- matrixTransformDistance :: MonadIO m => Matrix -> Double -> Double -> m (Double, Double)
- data MatrixTransformPointMethodInfo
- matrixTransformPoint :: MonadIO m => Matrix -> Double -> Double -> m (Double, Double)
- data MatrixTranslateMethodInfo
- matrixTranslate :: MonadIO m => Matrix -> Double -> Double -> m ()
- matrixReadX0 :: Matrix -> IO Double
- matrixReadXx :: Matrix -> IO Double
- matrixReadXy :: Matrix -> IO Double
- matrixReadY0 :: Matrix -> IO Double
- matrixReadYx :: Matrix -> IO Double
- matrixReadYy :: Matrix -> IO Double
Exported types
newZeroMatrix :: MonadIO m => m Matrix Source
Construct a Matrix
struct initialized to zero.
Methods
matrixConcat
data MatrixConcatMethodInfo Source
((~) (TYPE Lifted) signature (Matrix -> m ()), MonadIO m) => MethodInfo (TYPE Lifted) MatrixConcatMethodInfo Matrix signature Source | |
matrixConcat :: MonadIO m => Matrix -> Matrix -> m () Source
matrixCopy
data MatrixCopyMethodInfo Source
((~) (TYPE Lifted) signature (m Matrix), MonadIO m) => MethodInfo (TYPE Lifted) MatrixCopyMethodInfo Matrix signature Source | |
matrixCopy :: MonadIO m => Matrix -> m Matrix Source
matrixFree
data MatrixFreeMethodInfo Source
((~) (TYPE Lifted) signature (m ()), MonadIO m) => MethodInfo (TYPE Lifted) MatrixFreeMethodInfo Matrix signature Source | |
matrixFree :: MonadIO m => Matrix -> m () Source
matrixGetFontScaleFactor
data MatrixGetFontScaleFactorMethodInfo Source
((~) (TYPE Lifted) signature (m Double), MonadIO m) => MethodInfo (TYPE Lifted) MatrixGetFontScaleFactorMethodInfo Matrix signature Source | |
matrixGetFontScaleFactor :: MonadIO m => Matrix -> m Double Source
matrixGetFontScaleFactors
matrixRotate
data MatrixRotateMethodInfo Source
((~) (TYPE Lifted) signature (Double -> m ()), MonadIO m) => MethodInfo (TYPE Lifted) MatrixRotateMethodInfo Matrix signature Source | |
matrixRotate :: MonadIO m => Matrix -> Double -> m () Source
matrixScale
matrixTransformDistance
matrixTransformPoint
matrixTranslate
Properties
X0
matrixReadX0 :: Matrix -> IO Double Source
Xx
matrixReadXx :: Matrix -> IO Double Source
Xy
matrixReadXy :: Matrix -> IO Double Source
Y0
matrixReadY0 :: Matrix -> IO Double Source
Yx
matrixReadYx :: Matrix -> IO Double Source
Yy
matrixReadYy :: Matrix -> IO Double Source