Revert pictures to using lists rather than streams of Verx
This commit is contained in:
+8
-2
@@ -18,7 +18,13 @@ import Data.Maybe
|
||||
import Data.List
|
||||
import Data.Bifunctor
|
||||
import Control.Lens
|
||||
import qualified Streaming.Prelude as S
|
||||
--import qualified Streaming.Prelude as S
|
||||
|
||||
--picMap :: (Verx -> Verx) -> Picture -> Picture
|
||||
--picMap = map
|
||||
|
||||
picFormat :: [Verx] -> Picture
|
||||
picFormat = id
|
||||
|
||||
translateXY :: Float -> Float -> Polyhedra -> Polyhedra
|
||||
translateXY x y = pyFaces %~ map (map $ first tran)
|
||||
@@ -120,7 +126,7 @@ polyToPics :: Polyhedra -> [Picture]
|
||||
polyToPics = map helpPoly3D . _pyFaces
|
||||
|
||||
helpPoly3D :: [(Point3, Point4)] -> Picture
|
||||
helpPoly3D = S.each . map f . polyToTris
|
||||
helpPoly3D = picFormat . map f . polyToTris
|
||||
where
|
||||
f (pos,col) = Verx pos col [] BottomLayer polyNum
|
||||
|
||||
|
||||
Reference in New Issue
Block a user