Add various helpers for creating polyhedra
This commit is contained in:
+3
-3
@@ -1,6 +1,6 @@
|
||||
module MatrixHelper
|
||||
( perspectiveMatrixb
|
||||
, perspectiveMatrixc
|
||||
, isoMatrix
|
||||
) where
|
||||
--import Geometry
|
||||
import Geometry.Data
|
||||
@@ -28,13 +28,13 @@ perspectiveMatrixb rot zoom (tranx,trany) (winx,winy) (viewFromx,viewFromy) =
|
||||
!*! vertScale
|
||||
!*! vertTrans
|
||||
|
||||
perspectiveMatrixc
|
||||
isoMatrix
|
||||
:: Float -- ^ Rotation
|
||||
-> Float -- ^ Zoom
|
||||
-> Point2 -- ^ Translation
|
||||
-> Point2 -- ^ Window size
|
||||
-> [GLfloat]
|
||||
perspectiveMatrixc rot zoom (tranx,trany) (winx,winy) = concatMap vToL
|
||||
isoMatrix rot zoom (tranx,trany) (winx,winy) = concatMap vToL
|
||||
. vToL
|
||||
. lmt
|
||||
$ scaleMat (2*zoom/winx,2*zoom/winy)
|
||||
|
||||
Reference in New Issue
Block a user