Tweak clouds
This commit is contained in:
+40
-40
@@ -80,23 +80,23 @@ updateFBOTO xsize ysize minfilt magfilt inFormat pdata target = do
|
||||
newfbo2 <- resizeFBOTO (pdata ^# target) xsize ysize minfilt magfilt inFormat
|
||||
return $ storing target newfbo2 pdata
|
||||
|
||||
updateFBOTO2 ::
|
||||
Int ->
|
||||
Int ->
|
||||
-- | minification filter
|
||||
GLenum ->
|
||||
-- | magnification filter
|
||||
GLenum ->
|
||||
-- | internal color format texture1
|
||||
GLenum ->
|
||||
-- | internal color format texture2
|
||||
GLenum ->
|
||||
RenderData ->
|
||||
ALens' RenderData (FBO, (TO, TO)) ->
|
||||
IO RenderData
|
||||
updateFBOTO2 xsize ysize minfilt magfilt inFormat1 inFormat2 pdata target = do
|
||||
newfbo2 <- resizeFBOTO2 (pdata ^# target) xsize ysize minfilt magfilt inFormat1 inFormat2
|
||||
return $ storing target newfbo2 pdata
|
||||
--updateFBOTO2 ::
|
||||
-- Int ->
|
||||
-- Int ->
|
||||
-- -- | minification filter
|
||||
-- GLenum ->
|
||||
-- -- | magnification filter
|
||||
-- GLenum ->
|
||||
-- -- | internal color format texture1
|
||||
-- GLenum ->
|
||||
-- -- | internal color format texture2
|
||||
-- GLenum ->
|
||||
-- RenderData ->
|
||||
-- ALens' RenderData (FBO, (TO, TO)) ->
|
||||
-- IO RenderData
|
||||
--updateFBOTO2 xsize ysize minfilt magfilt inFormat1 inFormat2 pdata target = do
|
||||
-- newfbo2 <- resizeFBOTO2 (pdata ^# target) xsize ysize minfilt magfilt inFormat1 inFormat2
|
||||
-- return $ storing target newfbo2 pdata
|
||||
|
||||
updateFBOTO3 ::
|
||||
Int ->
|
||||
@@ -134,29 +134,29 @@ resizeShadowFBO (fbo, (oldto1, oldto2)) x y = do
|
||||
checkFBO fbo
|
||||
return (fbo, (TO to1, TO to2))
|
||||
|
||||
resizeFBOTO2 ::
|
||||
(FBO, (TO, TO)) ->
|
||||
Int ->
|
||||
Int ->
|
||||
-- | minification filter
|
||||
GLenum ->
|
||||
-- | magnification filter
|
||||
GLenum ->
|
||||
-- | internal color format1
|
||||
GLenum ->
|
||||
-- | internal color format2
|
||||
GLenum ->
|
||||
IO (FBO, (TO, TO))
|
||||
resizeFBOTO2 (fbo, (toOld1, toOld2)) xsize ysize minfilt magfilt inFormat1 inFormat2 = do
|
||||
glBindFramebuffer GL_FRAMEBUFFER (_unFBO fbo)
|
||||
mglDelete glDeleteTextures $ _unTO toOld1
|
||||
mglDelete glDeleteTextures $ _unTO toOld2
|
||||
to1 <- initializeTexture2D fbo GL_COLOR_ATTACHMENT0 xsize ysize minfilt magfilt inFormat1
|
||||
to2 <- initializeTexture2D fbo GL_COLOR_ATTACHMENT1 xsize ysize minfilt magfilt inFormat2
|
||||
withArray [GL_COLOR_ATTACHMENT0, GL_COLOR_ATTACHMENT1] $ \ptr ->
|
||||
glNamedFramebufferDrawBuffers (_unFBO fbo) 2 ptr
|
||||
checkFBO fbo
|
||||
return (fbo, (TO to1, TO to2))
|
||||
--resizeFBOTO2 ::
|
||||
-- (FBO, (TO, TO)) ->
|
||||
-- Int ->
|
||||
-- Int ->
|
||||
-- -- | minification filter
|
||||
-- GLenum ->
|
||||
-- -- | magnification filter
|
||||
-- GLenum ->
|
||||
-- -- | internal color format1
|
||||
-- GLenum ->
|
||||
-- -- | internal color format2
|
||||
-- GLenum ->
|
||||
-- IO (FBO, (TO, TO))
|
||||
--resizeFBOTO2 (fbo, (toOld1, toOld2)) xsize ysize minfilt magfilt inFormat1 inFormat2 = do
|
||||
-- glBindFramebuffer GL_FRAMEBUFFER (_unFBO fbo)
|
||||
-- mglDelete glDeleteTextures $ _unTO toOld1
|
||||
-- mglDelete glDeleteTextures $ _unTO toOld2
|
||||
-- to1 <- initializeTexture2D fbo GL_COLOR_ATTACHMENT0 xsize ysize minfilt magfilt inFormat1
|
||||
-- to2 <- initializeTexture2D fbo GL_COLOR_ATTACHMENT1 xsize ysize minfilt magfilt inFormat2
|
||||
-- withArray [GL_COLOR_ATTACHMENT0, GL_COLOR_ATTACHMENT1] $ \ptr ->
|
||||
-- glNamedFramebufferDrawBuffers (_unFBO fbo) 2 ptr
|
||||
-- checkFBO fbo
|
||||
-- return (fbo, (TO to1, TO to2))
|
||||
|
||||
resizeFBOTO3 ::
|
||||
(FBO, (TO, TO,TO)) ->
|
||||
|
||||
Reference in New Issue
Block a user