Try to add compute shaders
This commit is contained in:
+11
-6
@@ -20,7 +20,7 @@ import Dodge.Render
|
||||
import Dodge.SoundLogic.LoadSound
|
||||
import Dodge.TestString
|
||||
import Dodge.Update
|
||||
import qualified IntMapHelp as IM
|
||||
--import qualified IntMapHelp as IM
|
||||
import Loop
|
||||
import Music
|
||||
--import Picture
|
||||
@@ -30,7 +30,7 @@ import Preload.Render
|
||||
|
||||
import SDL (($=))
|
||||
import qualified SDL
|
||||
import qualified SDL.Mixer as Mix
|
||||
--import qualified SDL.Mixer as Mix
|
||||
import Sound
|
||||
import System.Directory
|
||||
|
||||
@@ -59,7 +59,7 @@ winConfig x y winpos =
|
||||
{ SDL.windowGraphicsContext =
|
||||
SDL.OpenGLContext $
|
||||
SDL.defaultOpenGL
|
||||
{ SDL.glProfile = SDL.Core SDL.Normal 4 3
|
||||
{ SDL.glProfile = SDL.Core SDL.Normal 4 5
|
||||
, SDL.glColorPrecision = SDL.V4 8 8 8 8
|
||||
}
|
||||
, SDL.windowPosition = theWinPos
|
||||
@@ -128,13 +128,18 @@ doSideEffects u = do
|
||||
|
||||
doPreload :: IO PreloadData
|
||||
doPreload = do
|
||||
putStrLn "Start Render preload"
|
||||
rData <- preloadRender
|
||||
putStrLn "Start sound preload"
|
||||
lChunks <- loadSounds
|
||||
lMusic <- loadMusic
|
||||
Mix.playMusic Mix.Forever (lMusic IM.! 0)
|
||||
putStrLn "Skip music preload!"
|
||||
-- lMusic <- loadMusic
|
||||
-- Mix.playMusic Mix.Forever (lMusic IM.! 0)
|
||||
putStrLn "Return PreloadData"
|
||||
return
|
||||
PreloadData
|
||||
{ _renderData = rData
|
||||
, _soundData = SoundData{_loadedChunks = lChunks}
|
||||
, _musicData = MusicData{_loadedMusic = lMusic}
|
||||
--, _musicData = MusicData{_loadedMusic = lMusic}
|
||||
, _musicData = MusicData{_loadedMusic = undefined}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user