minor fixture

This commit is contained in:
Nicole Dresselhaus 2014-05-13 12:52:00 +02:00
parent dd12f7b136
commit 13fbb9b816
No known key found for this signature in database
GPG Key ID: BC16D887851A1A80

View File

@ -403,14 +403,14 @@ render = do
checkError "setting up shadowmap-program" checkError "setting up shadowmap-program"
--set up projection (= copy from state) --set up projection (= copy from state)
--TODO: Fix --TODO: Fix width/depth
with (distribute (createFrustumOrtho 20 20 0 100)) $ \ptr -> with (distribute (createFrustumOrtho 20 20 0 100)) $ \ptr ->
glUniformMatrix4fv proj 1 0 (castPtr (ptr :: Ptr (L.M44 CFloat))) glUniformMatrix4fv proj 1 0 (castPtr (ptr :: Ptr (L.M44 CFloat)))
checkError "copy shadowmap-projection" checkError "copy shadowmap-projection"
--set up camera --set up camera
--TODO: Fix --TODO: Fix magic constants... and camPos
let ! cam = getCam camPos zDist' xa ya let ! cam = getCam camPos 1 0.7 0
with (distribute cam) $ \ptr -> with (distribute cam) $ \ptr ->
glUniformMatrix4fv vmat 1 0 (castPtr (ptr :: Ptr (L.M44 CFloat))) glUniformMatrix4fv vmat 1 0 (castPtr (ptr :: Ptr (L.M44 CFloat)))
checkError "copy shadowmap-cam" checkError "copy shadowmap-cam"