Cleanup window buffers

This commit is contained in:
2025-11-11 18:08:55 +00:00
parent ceba6fd533
commit f136d0cd19
4 changed files with 26 additions and 38 deletions
+5 -7
View File
@@ -69,7 +69,7 @@ doDrawing' win pdata u = do
wp
)
( pokeWallsWindows
(pdata ^. vboWindows . vboPtr)
(pdata ^. winVBO . vboPtr)
(pdata ^. wallVBO . vboPtr)
windowPoints
wallsToPoke
@@ -107,10 +107,11 @@ doDrawing' win pdata u = do
]
-- set the coordinate uniform ready for drawing elements using world coordinates
bufferPerspectiveMatrixUBO cfig (w ^. wCam) (pdata ^. matUBO)
glNamedBufferSubData (pdata ^. winSSBO) 0
glNamedBufferSubData (pdata ^. winVBO . vboName) 0
(fromIntegral $ nWins * sizeOf (0::Float) * 8)
(pdata ^. vboWindows . vboPtr)
glNamedBufferSubData (pdata ^. wallSSBO) 0
(pdata ^. winVBO . vboPtr)
-- bufferFloatBO function
glNamedBufferSubData (pdata ^. wallVBO . vboName) 0
(fromIntegral $ trueNWalls * sizeOf (0::Float) * 8)
(pdata ^. wallVBO . vboPtr)
glNamedBufferSubData (pdata ^. shapeSSBO) 0
@@ -120,9 +121,6 @@ doDrawing' win pdata u = do
(fromIntegral $ nIndices * (sizeOf (0::GLuint)))
(pdata ^. shapeEBO . uiboPtr)
bufferEBO (pdata ^. silhouetteEBO) nSilIndices
-- glNamedBufferSubData (pdata ^. ieshapeSSBO) 0
-- (fromIntegral $ nSilIndices * (sizeOf (0::GLuint)))
-- (pdata ^. silhouetteEBO . uiboPtr)
setViewport _gr_world_res cfig
glBindFramebuffer GL_FRAMEBUFFER (pdata ^. fboBase . _1 . unFBO)
glDepthMask GL_TRUE