Tweak flamer flame drawing
This commit is contained in:
+14
-11
@@ -105,18 +105,22 @@ doDrawing pdata w = do
|
|||||||
|
|
||||||
bindFramebuffer Framebuffer $= fst (_fboBloom pdata)
|
bindFramebuffer Framebuffer $= fst (_fboBloom pdata)
|
||||||
clear [ColorBuffer]
|
clear [ColorBuffer]
|
||||||
|
--blendFunc $= (SrcAlpha,OneMinusSrcAlpha)
|
||||||
blendFunc $= (SrcAlpha,OneMinusSrcAlpha)
|
blendFunc $= (SrcAlpha,OneMinusSrcAlpha)
|
||||||
|
--blendEquation $= Max
|
||||||
renderLayer 1 shadV layerCounts
|
|
||||||
bindFramebuffer Framebuffer $= fst (_fboColor pdata)
|
|
||||||
clear [ColorBuffer]
|
|
||||||
depthMask $= Disabled
|
depthMask $= Disabled
|
||||||
|
|
||||||
renderLayer 3 shadV layerCounts
|
renderLayer 3 shadV layerCounts
|
||||||
renderLayer 4 shadV layerCounts
|
|
||||||
renderLayer 5 shadV layerCounts
|
|
||||||
|
|
||||||
depthMask $= Enabled
|
depthMask $= Enabled
|
||||||
|
renderLayer 1 shadV layerCounts
|
||||||
|
-- bindFramebuffer Framebuffer $= fst (_fboColor pdata)
|
||||||
|
-- clear [ColorBuffer]
|
||||||
|
-- depthMask $= Disabled
|
||||||
|
-- blendEquation $= FuncAdd
|
||||||
|
-- renderLayer 3 shadV layerCounts
|
||||||
|
-- renderLayer 4 shadV layerCounts
|
||||||
|
-- renderLayer 5 shadV layerCounts
|
||||||
|
--
|
||||||
|
-- depthMask $= Enabled
|
||||||
-- this is not ideal if the original is not divisible by 2
|
-- this is not ideal if the original is not divisible by 2
|
||||||
viewport $= (Position 0 0
|
viewport $= (Position 0 0
|
||||||
, divideSize (2 * (w ^. config . shadow_resolution)) $ Size (round $ fstV2 wins) (round $ sndV2 wins))
|
, divideSize (2 * (w ^. config . shadow_resolution)) $ Size (round $ fstV2 wins) (round $ sndV2 wins))
|
||||||
@@ -149,9 +153,8 @@ doDrawing pdata w = do
|
|||||||
drawShader (_fullscreenShader pdata) 4
|
drawShader (_fullscreenShader pdata) 4
|
||||||
blendFunc $= (SrcAlpha, OneMinusSrcAlpha)
|
blendFunc $= (SrcAlpha, OneMinusSrcAlpha)
|
||||||
|
|
||||||
textureBinding Texture2D $= Just (snd $ _fboColor pdata)
|
--textureBinding Texture2D $= Just (snd $ _fboColor pdata)
|
||||||
drawShader (_colorBlurShader pdata) 4
|
--drawShader (_colorBlurShader pdata) 4
|
||||||
--textureBinding Texture2D $= Just (snd3 $ _fbo2 pdata)
|
|
||||||
blendFunc $= (SrcAlpha, One)
|
blendFunc $= (SrcAlpha, One)
|
||||||
textureBinding Texture2D $= Just (snd $ _fboFourth1 pdata)
|
textureBinding Texture2D $= Just (snd $ _fboFourth1 pdata)
|
||||||
drawShader (_fullscreenShader pdata) 4
|
drawShader (_fullscreenShader pdata) 4
|
||||||
|
|||||||
@@ -51,7 +51,6 @@ aFlameParticle t pos vel maycid = Pt'
|
|||||||
, _btTimer' = t
|
, _btTimer' = t
|
||||||
, _btHitEffect' = destroyOnImpact (doFlameDam 1) noEff noEff
|
, _btHitEffect' = destroyOnImpact (doFlameDam 1) noEff noEff
|
||||||
}
|
}
|
||||||
|
|
||||||
drawFlame
|
drawFlame
|
||||||
:: Point2 -- ^ Rotate direction
|
:: Point2 -- ^ Rotate direction
|
||||||
-> Particle -> Picture
|
-> Particle -> Picture
|
||||||
@@ -60,8 +59,8 @@ drawFlame rotd pt = thePic
|
|||||||
ep = _btPos' pt
|
ep = _btPos' pt
|
||||||
thePic = pictures
|
thePic = pictures
|
||||||
[ glow
|
[ glow
|
||||||
, aPic 1 prot2 18 (V2 (scaleChange + 1) 2 ) $ V4 2 (-1) (-1) 0.5
|
, aPic 3 prot2 25 (V2 (scaleChange + 1) 2 ) $ V4 2 (-1) (-1) 0.5
|
||||||
, aPic 1 prot 19 (V2 (scaleChange + 0.5) 1) $ V4 1 0.5 0 2
|
, aPic 3 prot 22 (V2 (scaleChange + 0.5) 1) $ V4 1 0.5 0 2
|
||||||
, aPic 1 prot3 20 (V2 scaleChange 0.5 ) $ V4 1 1 1 1
|
, aPic 1 prot3 20 (V2 scaleChange 0.5 ) $ V4 1 1 1 1
|
||||||
]
|
]
|
||||||
aPic :: Int -> (Point2 -> Point2) -> Float -> Point2 -> Color -> Picture
|
aPic :: Int -> (Point2 -> Point2) -> Float -> Point2 -> Color -> Picture
|
||||||
@@ -171,8 +170,8 @@ drawFlameletZ rot pt = pictures
|
|||||||
--, setLayer 4 pi2
|
--, setLayer 4 pi2
|
||||||
--, setLayer 3 piu
|
--, setLayer 3 piu
|
||||||
[ setLayer 1 pic
|
[ setLayer 1 pic
|
||||||
, setLayer 1 pi2
|
, setLayer 3 piu
|
||||||
, setLayer 1 piu
|
, setLayer 3 pi2
|
||||||
--, setLayer 1 glow
|
--, setLayer 1 glow
|
||||||
]
|
]
|
||||||
where
|
where
|
||||||
|
|||||||
Reference in New Issue
Block a user