-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | a simple physics engine -- -- A simple physics engine(dynamics only) with collision dection @package light @version 0.2.0.1 module Physics.Light data Object2D Object2D :: V3 Double -> V3 Double -> [Convex] -> Object2D [_position] :: Object2D -> V3 Double [_velocity] :: Object2D -> V3 Double [_shape] :: Object2D -> [Convex] velocity :: Lens' Object2D (V3 Double) shape :: Lens' Object2D [Convex] position :: Lens' Object2D (V3 Double) type PhysicsWorld = (IntMap Object2D, Int) newPhysicsWorld :: PhysicsWorld addObject :: Object2D -> PhysicsWorld -> PhysicsWorld addObjects :: [Object2D] -> PhysicsWorld -> PhysicsWorld update :: Double -> IntMap Object2D -> IntMap Object2D updateObject2D :: Double -> Object2D -> Object2D detectCollision :: IntMap Object2D -> [(Int, Int)] detect :: IntMap Object2D -> Int -> Object2D -> [Int] shapeCollide :: [Convex] -> [Convex] -> Bool ellipse :: Double -> Double -> Convex circle :: Double -> Convex polygon :: [V2 Double] -> Convex moveConvex :: V2 Double -> Convex -> Convex rotateConvex :: Double -> Convex -> Convex scaleConvex :: V2 Double -> Convex -> Convex rotateMatrix2D :: Double -> V2 (V2 Double) worldToLocal :: V3 Double -> V3 Double -> V3 Double localToWorld :: V3 Double -> V3 Double -> V3 Double instance GHC.Show.Show Physics.Light.Object2D