got rid of single binding

This commit is contained in:
Nicole Dresselhaus 2014-10-24 22:40:57 +02:00
parent 197e1a84d7
commit b034d6b942

View File

@ -56,8 +56,7 @@ diffuse (Collision pos n _ obj) s (Light lpos color int) =
else
ill
where
ill = (*) (dot n $ normalize lightdir) <$> illumination
illumination = (*) <$> color ^* i <*> materialDiffuse mat
ill = (*) (dot n $ normalize lightdir) <$> ((*) <$> color ^* i <*> materialDiffuse mat)
mat = getMaterial obj
blocked = raytrace (Ray pos lightdir) s
lightdir = (lpos ^-^ pos)