Hopefully fully excise streaming

This commit is contained in:
2022-08-22 12:02:42 +01:00
parent b7a77cdbd9
commit aeb22fc9d7
10 changed files with 6 additions and 54 deletions
+2 -2
View File
@@ -21,7 +21,7 @@ import qualified Data.Vector.Mutable as MV
import Control.Monad.Primitive
import Graphics.GL.Core43
import Control.Monad
import qualified Streaming.Prelude as S
import qualified Data.Vector.Fusion.Stream.Monadic as VFSM
divideSize :: Int -> Size -> Size
divideSize i (Size x y) = Size (div x $ fromIntegral i) (div y $ fromIntegral i)
@@ -53,7 +53,7 @@ createLightMap pdata lightPoints nWalls nSils nCaps drawObjShads toPos = do
-- to consider: adding normals/a "material" for each fragment
blendFunc $= (Zero, OneMinusSrcColor)
stencilTest $= Enabled
flip S.mapM_ (S.each lightPoints) $ \(V3 x y z,rad,V3 r g b) -> do
flip VFSM.mapM_ (VFSM.fromList lightPoints) $ \(V3 x y z,rad,V3 r g b) -> do
depthFunc $= Just Less
-- setup stencil
colorMask $= Color4 Disabled Disabled Disabled Disabled