Refactor shader types

This commit is contained in:
2023-03-22 14:08:07 +00:00
parent c0579fae00
commit 5769477ad4
20 changed files with 303 additions and 330 deletions
+21 -27
View File
@@ -10,34 +10,30 @@ import qualified Data.Vector.Mutable as MV
import Graphics.GL.Core45
import Shader.Data
newtype FBO = FBO {_unFBO :: GLuint}
newtype TO = TO {_unTO :: GLuint}
data RenderData = RenderData
{ _lightingWallShadShader :: FullShader
, _lightingLineShadowShader :: FullShader
, _lightingCapShader :: FullShader
, _lightingTextureShader :: FullShader
{ _lightingWallShadShader :: Shader
, _lightingLineShadowShader :: Shader
, _lightingCapShader :: Shader
, _lightingTextureShader :: Shader
, _alphaDivideShader :: Shader
, _shadowEdgeShader :: FullShader
, _shadowCapShader :: FullShader
, _shadowWallShader :: FullShader
, _shadowLightShader :: (FullShader,VBO)
, _shadowCombineShader :: (FullShader,VBO)
, _positionalBlankShader :: (FullShader,VBO)
, _wallBlankShader :: FullShader
, _windowShader :: FullShader
, _wallTextureShader :: FullShader
, _shadowEdgeShader :: Shader
, _shadowCapShader :: Shader
, _shadowWallShader :: Shader
, _shadowLightShader :: (Shader,VBO)
, _shadowCombineShader :: (Shader,VBO)
, _positionalBlankShader :: (Shader,VBO)
, _wallBlankShader :: Shader
, _windowShader :: Shader
, _wallTextureShader :: Shader
, _fullscreenShader :: Shader
, _bloomBlurShader :: FullShader
, _colorBlurShader :: FullShader
, _barrelShader :: (FullShader,VBO)
, _grayscaleShader :: FullShader
, _shapeShader :: FullShader
, _bloomBlurShader :: Shader
, _colorBlurShader :: Shader
, _barrelShader :: (Shader,VBO)
, _grayscaleShader :: Shader
, _shapeShader :: Shader
, _shapeEBO :: EBO
, _silhouetteEBO :: EBO
, _pictureShaders :: MV.MVector (PrimState IO) (FullShader,VBO)
, _pictureShaders :: MV.MVector (PrimState IO) (Shader,VBO)
, _fbo2 :: (FBO, TO)
, _fbo3 :: (FBO, TO)
, _fboHalf1 :: (FBO, TO)
@@ -57,11 +53,11 @@ data RenderData = RenderData
, _vboWindows :: VBO
, _vboShapes :: VBO
, _floorVBO :: VBO
, _floorShader :: FullShader
, _floorShader :: Shader
, _toNormalMaps :: TO
, _toDiffuse :: TO
, _wallVBO :: VBO
, _wallShader :: FullShader
, _wallShader :: Shader
, _cloudVBO :: VBO
, _cloudShader :: Shader
, _cloudEBO :: EBO
@@ -69,5 +65,3 @@ data RenderData = RenderData
}
makeLenses ''RenderData
makeLenses ''FBO
makeLenses ''TO