From ab976b4af69e8bbac992bcba76a5368e0863051f Mon Sep 17 00:00:00 2001 From: nek0 Date: Tue, 20 Dec 2016 04:15:30 +0100 Subject: [PATCH] this was the bad performance bottleneck --- src/Affection/Draw.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Affection/Draw.hs b/src/Affection/Draw.hs index 59cf3fe..6237c83 100644 --- a/src/Affection/Draw.hs +++ b/src/Affection/Draw.hs @@ -101,7 +101,7 @@ handleDrawRequest -> Affection us (Maybe DrawRequest) handleDrawRequest pixels format stride cpp dr@DrawRequest{..} = do ad <- get - let !surf = drawSurface ad + let surf = drawSurface ad liftIO $ SDL.lockSurface surf liftIO $ G.gegl_node_blit requestNode @@ -113,7 +113,7 @@ handleDrawRequest pixels format stride cpp dr@DrawRequest{..} = do stride [G.GeglBlitDefault] liftIO $ SDL.unlockSurface surf - liftIO $ SDL.updateWindowSurface $ drawWindow ad + -- liftIO $ SDL.updateWindowSurface $ drawWindow ad if requestPersist then return Nothing @@ -143,7 +143,7 @@ invalidateDrawRequest pixels format stride cpp dr@DrawRequest{..} = do stride [G.GeglBlitDefault] liftIO $ SDL.unlockSurface surf - liftIO $ SDL.updateWindowSurface $ drawWindow ad + -- liftIO $ SDL.updateWindowSurface $ drawWindow ad -- | compute color for a single pixel colorize