reanimate-0.4.0.0: Animation library based on SVGs.

Safe HaskellNone
LanguageHaskell2010

Reanimate.Math.DCEL

Documentation

data Mesh a Source #

Instances
Show a => Show (Mesh a) Source # 
Instance details

Defined in Reanimate.Math.DCEL

Methods

showsPrec :: Int -> Mesh a -> ShowS #

show :: Mesh a -> String #

showList :: [Mesh a] -> ShowS #

data Vertex a Source #

Constructors

Vertex 
Instances
Show a => Show (Vertex a) Source # 
Instance details

Defined in Reanimate.Math.DCEL

Methods

showsPrec :: Int -> Vertex a -> ShowS #

show :: Vertex a -> String #

showList :: [Vertex a] -> ShowS #

data Edge Source #

Instances
Show Edge Source # 
Instance details

Defined in Reanimate.Math.DCEL

Methods

showsPrec :: Int -> Edge -> ShowS #

show :: Edge -> String #

showList :: [Edge] -> ShowS #

data Face Source #

Constructors

Face 
Instances
Show Face Source # 
Instance details

Defined in Reanimate.Math.DCEL

Methods

showsPrec :: Int -> Face -> ShowS #

show :: Face -> String #

showList :: [Face] -> ShowS #

type MeshM position a = State (Mesh position) a Source #

meshVertices :: forall a a. Lens (Mesh a) (Mesh a) (Map VertexId (Vertex a)) (Map VertexId (Vertex a)) Source #

meshIdCounter :: forall a. Lens' (Mesh a) Int Source #

meshFaces :: forall a. Lens' (Mesh a) (Map FaceId Face) Source #

meshEdges :: forall a. Lens' (Mesh a) (Map EdgeId Edge) Source #

vertexPosition :: forall a a. Lens (Vertex a) (Vertex a) a a Source #

ppMesh :: Show a => Mesh a -> String Source #

polygonsMesh :: Eq a => [a] -> [[a]] -> MeshM a () Source #

polygonMesh :: [a] -> MeshM a () Source #

modifyVertex :: (Vertex a -> Vertex a) -> VertexId -> State (Mesh a) () Source #

withEdge :: EdgeId -> (Edge -> State (Mesh a) ()) -> State (Mesh a) () Source #

modifyEdge :: (Edge -> Edge) -> EdgeId -> State (Mesh a) () Source #

modifyFace :: (Face -> Face) -> FaceId -> State (Mesh a) () Source #

applyCompatible :: (t -> Mesh a -> Maybe (Mesh a)) -> (Mesh a -> [t]) -> Mesh a -> Mesh a -> (Mesh a, Mesh a) Source #