Work on lightmaps, add file

This commit is contained in:
2023-03-23 23:42:09 +00:00
parent 1abfaa3cd0
commit 9a66a09f96
9 changed files with 157 additions and 183 deletions
+6 -4
View File
@@ -80,13 +80,15 @@ makeShaderUsingVBO ::
[GLenum] ->
-- | The input vertex sizes
[Int] ->
-- | The stride
Int ->
PrimitiveMode ->
VBO ->
IO Shader
makeShaderUsingVBO s shaderlist sizes strd pm vbo = setupVAOvbo sizes strd vbo
>>= makeShaderUsingVAO s shaderlist pm
makeShaderUsingVBO s shaderlist sizes pm vbo = do
let strd = vbo ^. vboVertexSize
when (strd < sum sizes) $
error "Tried to assign vertex attributes to VBO with too small a stride."
vao <- setupVAOvbo sizes strd vbo
makeShaderUsingVAO s shaderlist pm vao
setupVBO :: Int -> IO VBO
setupVBO vertexsize = do