Work towards using vertex pulling for lighting caps, alignment issues

This commit is contained in:
2025-11-11 12:33:33 +00:00
parent 36d5edc0a6
commit a65a1cab93
9 changed files with 173 additions and 100 deletions
+15 -6
View File
@@ -197,12 +197,21 @@ renderShadows shadrendertype nWalls nSils nCaps positiontexture normaltexture li
glCullFace GL_FRONT
glUseProgram (_shaderUINT lcapShad)
glUniform3f 0 x y z
glBindVertexArray $ lcapShad ^. shaderVAO . vaoName --Just (_vao $ _shadVAO lcapShad)
glDrawElements
(_unPrimitiveMode $ _shaderPrimitive lcapShad)
(fromIntegral nCaps)
GL_UNSIGNED_SHORT
nullPtr
glUniform4f 1 r g b rad
--glBindVertexArray $ lcapShad ^. shaderVAO . vaoName --Just (_vao $ _shadVAO lcapShad)
glBindVertexArray $ pdata ^. dummyVAO . vaoName
glFrontFace(GL_CW)
glDrawArrays
GL_TRIANGLES
0
3
--(fromIntegral nCaps)
glFrontFace(GL_CCW)
--glDrawElements
-- (_unPrimitiveMode $ _shaderPrimitive lcapShad)
-- (fromIntegral nCaps)
-- GL_UNSIGNED_SHORT
-- nullPtr
glDisable GL_DEPTH_CLAMP
_ -> return ()
--draw lightmap itself