Clear all warnings
This commit is contained in:
+11
-11
@@ -42,7 +42,7 @@ picToLTree mx (LineCol i vs)
|
||||
where (ps,cs) = unzip vs
|
||||
picToLTree mx (Text i s)
|
||||
= filtB mx i $ LLeaf $ RenderText $ stringToList s
|
||||
picToLTree j Blank = LBranches []
|
||||
picToLTree _ Blank = LBranches []
|
||||
picToLTree j (Pictures pics) = LBranches $ map (picToLTree j) pics
|
||||
picToLTree j (OverPic f f' r f'' (OverPic g g' s g'' pic))
|
||||
= picToLTree j $ OverPic (f . g) (f' . g') (r + s) (f'' . g'') pic
|
||||
@@ -64,6 +64,7 @@ doubleLine :: [a] -> [a]
|
||||
doubleLine (x:y:xs) = concat $ zipWith (:) (init (x:y:xs)) $ map (: []) (y:xs)
|
||||
doubleLine _ = []
|
||||
|
||||
white, black :: Color
|
||||
white = (1,1,1,1)
|
||||
black = (0,0,0,1)
|
||||
|
||||
@@ -102,7 +103,7 @@ overCol f (RenderArc (a,b,c)) = RenderArc (a,f b,c)
|
||||
overSca :: (Point2 -> Point2) -> RenderType -> RenderType
|
||||
{-# INLINE overSca #-}
|
||||
overSca f (RenderText vs) = RenderText $ map (scaleT (f (1,1))) vs
|
||||
overSca f p = p
|
||||
overSca _ p = p
|
||||
|
||||
stringToList :: String -> [(Point3,Point4,Point3)]
|
||||
{-# INLINE stringToList #-}
|
||||
@@ -123,12 +124,11 @@ translate3 :: Float -> Float -> Point3 -> Point3
|
||||
{-# INLINE translate3 #-}
|
||||
translate3 a b (x,y,z) = (x+a,y+b,z)
|
||||
{- Scale a 3D vector in the x and y directions. -}
|
||||
scale3 :: Float -> Float -> Point3 -> Point3
|
||||
{-# INLINE scale3 #-}
|
||||
scale3 a b (x,y,z) = (x*a,y*b,z)
|
||||
{- Rotate a 3D vector in the x-y plane. -}
|
||||
rotate3 :: Float -> Point3 -> Point3
|
||||
{-# INLINE rotate3 #-}
|
||||
rotate3 a (x,y,z) = (x',y',z)
|
||||
where (x',y') = rotateV a (x,y)
|
||||
|
||||
--scale3 :: Float -> Float -> Point3 -> Point3
|
||||
--{-# INLINE scale3 #-}
|
||||
--scale3 a b (x,y,z) = (x*a,y*b,z)
|
||||
--{- Rotate a 3D vector in the x-y plane. -}
|
||||
--rotate3 :: Float -> Point3 -> Point3
|
||||
--{-# INLINE rotate3 #-}
|
||||
--rotate3 a (x,y,z) = (x',y',z)
|
||||
-- where (x',y') = rotateV a (x,y)
|
||||
|
||||
Reference in New Issue
Block a user