Hoogle Search
Within LTS Haskell 24.52 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
m44Deformation :: Fractional n => M44 n -> Deformation V3 V2 ndiagrams-lib Diagrams.ThreeD.Projection Make a deformation from a 4x4 homogeneous matrix.
module Diagrams.ThreeD.
Transform Transformations specific to three dimensions, with a few generic transformations (uniform scaling, translation) also re-exported for convenience.
-
Affine transformations, parameterized by any vector space. For transformations on particular vector spaces, see e.g. Diagrams.TwoD.Transform.
-
diagrams-lib Diagrams.Transform Type class for things t which can be transformed.
data
Transformation (v :: Type -> Type) ndiagrams-lib Diagrams.Transform General (affine) transformations, represented by an invertible linear map, its transpose, and a vector representing a translation component. By the transpose of a linear map we mean simply the linear map corresponding to the transpose of the map's matrix representation. For example, any scale is its own transpose, since scales are represented by matrices with zeros everywhere except the diagonal. The transpose of a rotation is the same as its inverse. The reason we need to keep track of transposes is because it turns out that when transforming a shape according to some linear map L, the shape's normal vectors transform according to L's inverse transpose. (For a more detailed explanation and proof, see https://wiki.haskell.org/Diagrams/Dev/Transformations.) This is exactly what we need when transforming bounding functions, which are defined in terms of perpendicular (i.e. normal) hyperplanes. For more general, non-invertible transformations, see Diagrams.Deform (in diagrams-lib).
transform :: Transformable t => Transformation (V t) (N t) -> t -> tdiagrams-lib Diagrams.Transform Apply a transformation to an object.
-
diagrams-lib Diagrams.Transform Use a Transformation to make an Iso between an object transformed and untransformed. This is useful for carrying out functions under another transform:
under (transformed t) f == transform (inv t) . f . transform t under (transformed t1) (transform t2) == transform (conjugate t1 t2) transformed t ## a == transform t a a ^. transformed t == transform (inv t) a
-
No documentation available.
module Diagrams.TwoD.
Transform Transformations specific to two dimensions, with a few generic transformations (uniform scaling, translation) also re-exported for convenience.
natTransformRetryPolicy :: (forall a . () => m a -> n a) -> RetryPolicyM m -> RetryPolicyM nretry Control.Retry Applies a natural transformation to a policy to run a RetryPolicy meant for the monad m in the monad n provided a transformation from m to n is available. A common case is if you have a pure policy, RetryPolicyM Identity and want to use it to govern an IO computation you could write:
purePolicyInIO :: RetryPolicyM Identity -> RetryPolicyM IO purePolicyInIO = natTransformRetryPolicy (pure . runIdentity)