Revert "Continue transfer to mutable vectors"

This reverts commit 1f2f5431c0.
This commit is contained in:
2021-08-12 00:57:57 +02:00
parent 1f2f5431c0
commit 724f9a86f8
5 changed files with 44 additions and 50 deletions
+4 -4
View File
@@ -12,7 +12,7 @@ module Shader
import Shader.Data
import Shader.Parameters
import Shader.ExtraPrimitive
--import Shader.Poke
import Shader.Poke
--import Layers
--import MatrixHelper
@@ -82,15 +82,15 @@ drawShaderLay l fs i = do
drawShaderLay' :: Int -> UMV.MVector (PrimState IO) Int -> Int -> VShader -> IO ()
{-# INLINE drawShaderLay' #-}
drawShaderLay' theLayer shaderOffsetsVector shaderIndex fs = do
i <- UMV.read shaderOffsetsVector shaderIndex
drawShaderLay' l countsVector index fs = do
i <- UMV.read countsVector index
currentProgram $= Just (_vshaderProgram fs)
bindVertexArrayObject $= Just (_vao $ _vshaderVAO fs)
case _vshaderTexture fs of
Just ShaderTexture{_textureObject = txo}
-> textureBinding Texture2D $= Just txo
_ -> return ()
glDrawArrays (marshalEPrimitiveMode $ _vshaderDrawPrimitive fs) (fromIntegral $ theLayer*numSubElements) (fromIntegral i)
glDrawArrays (marshalEPrimitiveMode $ _vshaderDrawPrimitive fs) (fromIntegral $ l*numSubElements) (fromIntegral i)
drawShader :: FullShader -> Int -> IO ()
{-# INLINE drawShader #-}