packages feed

HGamer3D-SFML-Binding 0.2.0 → 0.3.0

raw patch · 63 files changed

+1238/−2743 lines, 63 filesdep ~HGamer3D-Datasetup-changed

Dependency ranges changed: HGamer3D-Data

Files

HGamer3D-SFML-Binding.cabal view
@@ -1,13 +1,13 @@ Name:                HGamer3D-SFML-Binding
-Version:             0.2.0
-Synopsis:            Windows Game Engine for the Haskell Programmer - SFML Bindings
+Version:             0.3.0
+Synopsis:            SFML Binding for HGamer3D
 Description:         
-   HGamer3D is a game engine for developing 3D games in the programming 
-   language Haskell. The game engine uses available libraries for 3D graphics, 
-   sound, input device handling, gui programming and other areas and make
-   those functions available for the Haskell programmer by providing  
-   a Haskell API on top of that. HGamer3D is available on Windows only.
-   
+   HGamer3D is a game engine for developing 3D games in the programming +   language Haskell. This package provides the SFML binding. +   HGamer3D-SFML-Binding is available on Windows and Linux. +   This binding does not claim to have full coverage of SFML +   functionality, but only to support what is needed for the+   HGamer3D-Audio and HGamer3D-InputSystem packages. 
 	
 License:             OtherLicense
@@ -18,12 +18,12 @@ Cabal-Version:       >=1.4
 Homepage:            http://www.hgamer3d.org
 Category:            Game Engine, Audio, Graphics
-Extra-source-files:  Setup.hs, include/ClassJoystick.h, include/ClassKeyboard.h, include/ClassListener.h, include/ClassMouse.h, include/ClassMouseHG3D.h, include/ClassMusic.h, include/ClassPtr.h, include/ClassSound.h, include/ClassSoundBuffer.h, include/ClassSoundSource.h, include/ClassSoundStream.h, include/EnumJoystickAxis.h, include/EnumKey.h, include/EnumMouseButton.h, include/EnumSoundSourceStatus.h, include/SFMLDllDefines.h, include/StructHG3DClass.h, include/StructVec3.h
+Extra-source-files:  Setup.hs, include/vector2istruct.h, include/vector2fstruct.h, include/MouseHG3D.h, include/vector3istruct.h, include/hg3dstruct.h, include/vector3fstruct.h
 
 Library
-  Build-Depends:     base >= 3 && < 5, HGamer3D-Data >= 0.2.0
+  Build-Depends:     base >= 3 && < 5, HGamer3D-Data >= 0.3.0
 
-  Exposed-modules:   HGamer3D.Bindings.SFML.Utils, HGamer3D.Bindings.SFML.ClassPtr, HGamer3D.Bindings.SFML.StructHG3DClass, HGamer3D.Bindings.SFML.EnumJoystickAxis, HGamer3D.Bindings.SFML.EnumKey, HGamer3D.Bindings.SFML.EnumMouseButton, HGamer3D.Bindings.SFML.EnumSoundSourceStatus, HGamer3D.Bindings.SFML.StructVec3, HGamer3D.Bindings.SFML.ClassJoystick, HGamer3D.Bindings.SFML.ClassKeyboard, HGamer3D.Bindings.SFML.ClassListener, HGamer3D.Bindings.SFML.ClassMouse, HGamer3D.Bindings.SFML.ClassMouseHG3D, HGamer3D.Bindings.SFML.ClassMusic, HGamer3D.Bindings.SFML.ClassSound, HGamer3D.Bindings.SFML.ClassSoundBuffer, HGamer3D.Bindings.SFML.ClassSoundSource, HGamer3D.Bindings.SFML.ClassSoundStream
+  Exposed-modules:   HGamer3D.Bindings.SFML.Utils, HGamer3D.Bindings.SFML.StructHG3DClass, HGamer3D.Bindings.SFML.ClassPtr, HGamer3D.Bindings.SFML.EnumJoystickAxis, HGamer3D.Bindings.SFML.EnumKey, HGamer3D.Bindings.SFML.EnumSoundSourceStatus, HGamer3D.Bindings.SFML.EnumMouseButton, HGamer3D.Bindings.SFML.StructVec3, HGamer3D.Bindings.SFML.ClassListener, HGamer3D.Bindings.SFML.ClassJoystick, HGamer3D.Bindings.SFML.ClassMouseHG3D, HGamer3D.Bindings.SFML.ClassSoundStream, HGamer3D.Bindings.SFML.ClassSoundBuffer, HGamer3D.Bindings.SFML.ClassSoundSource, HGamer3D.Bindings.SFML.ClassKeyboard, HGamer3D.Bindings.SFML.ClassMouse, HGamer3D.Bindings.SFML.ClassSound, HGamer3D.Bindings.SFML.ClassMusic
   Other-modules:     
 
   ghc-options:       
@@ -32,4 +32,7 @@   Include-dirs:      include
   Build-tools:       
   build-depends:     
-  extra-libraries:   
+  if os(windows)
+     extra-libraries:   hg3dsfml030
+  else
+     extra-libraries:   hg3dsfml030,:libsfml-audio.so.2,:libsfml-system.so.2,:libsfml-window.so.2
+ HGamer3D/Bindings/SFML/ClassJoystick.chs view
@@ -0,0 +1,76 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassJoystick.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassJoystick where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+{# import HGamer3D.Bindings.SFML.EnumJoystickAxis #}+
+#include "ClassJoystick.h"
+{- function isConnected -}+{#fun sfml_jst_isConnected as isConnected +{ fromIntegral `Int' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function getButtonCount -}+{#fun sfml_jst_getButtonCount as getButtonCount +{ fromIntegral `Int' ,+ alloca- `Int' peekIntConv*} -> `()'  #}++{- function hasAxis -}+{#fun sfml_jst_hasAxis as hasAxis +{ fromIntegral `Int' ,+ cIntFromEnum `EnumJoystickAxis' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function isButtonPressed -}+{#fun sfml_jst_isButtonPressed as isButtonPressed +{ fromIntegral `Int' ,+ fromIntegral `Int' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function getAxisPosition -}+{#fun sfml_jst_getAxisPosition as getAxisPosition +{ fromIntegral `Int' ,+ cIntFromEnum `EnumJoystickAxis' ,+ alloca- `Float' peekFloatConv*} -> `()'  #}++{- function update -}+{#fun sfml_jst_update as update +{ } -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassJoystick.hs
@@ -1,130 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassJoystick.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassJoystick where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-import HGamer3D.Bindings.SFML.EnumJoystickAxis
-{-# LINE 43 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function isConnected -}
-isConnected :: Int -> IO (Bool)
-isConnected a1 =
-  let {a1' = fromIntegral a1} in 
-  alloca $ \a2' -> 
-  isConnected'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 49 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function getButtonCount -}
-getButtonCount :: Int -> IO (Int)
-getButtonCount a1 =
-  let {a1' = fromIntegral a1} in 
-  alloca $ \a2' -> 
-  getButtonCount'_ a1' a2' >>= \res ->
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 54 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function hasAxis -}
-hasAxis :: Int -> EnumJoystickAxis -> IO (Bool)
-hasAxis a1 a2 =
-  let {a1' = fromIntegral a1} in 
-  let {a2' = cIntFromEnum a2} in 
-  alloca $ \a3' -> 
-  hasAxis'_ a1' a2' a3' >>= \res ->
-  peekBoolUtil  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 60 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function isButtonPressed -}
-isButtonPressed :: Int -> Int -> IO (Bool)
-isButtonPressed a1 a2 =
-  let {a1' = fromIntegral a1} in 
-  let {a2' = fromIntegral a2} in 
-  alloca $ \a3' -> 
-  isButtonPressed'_ a1' a2' a3' >>= \res ->
-  peekBoolUtil  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 66 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function getAxisPosition -}
-getAxisPosition :: Int -> EnumJoystickAxis -> IO (Float)
-getAxisPosition a1 a2 =
-  let {a1' = fromIntegral a1} in 
-  let {a2' = cIntFromEnum a2} in 
-  alloca $ \a3' -> 
-  getAxisPosition'_ a1' a2' a3' >>= \res ->
-  peekFloatConv  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 72 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-{- function update -}
-update :: IO ()
-update =
-  update'_ >>= \res ->
-  return ()
-{-# LINE 76 ".\\HGamer3D\\Bindings\\SFML\\ClassJoystick.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_isConnected"
-  isConnected'_ :: (CUInt -> ((Ptr CInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_getButtonCount"
-  getButtonCount'_ :: (CUInt -> ((Ptr CUInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_hasAxis"
-  hasAxis'_ :: (CUInt -> (CInt -> ((Ptr CInt) -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_isButtonPressed"
-  isButtonPressed'_ :: (CUInt -> (CUInt -> ((Ptr CInt) -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_getAxisPosition"
-  getAxisPosition'_ :: (CUInt -> (CInt -> ((Ptr CFloat) -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassJoystick.chs.h sfml_jst_update"
-  update'_ :: (IO ())
+ HGamer3D/Bindings/SFML/ClassKeyboard.chs view
@@ -0,0 +1,49 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassKeyboard.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassKeyboard where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+{# import HGamer3D.Bindings.SFML.EnumKey #}+
+#include "ClassKeyboard.h"
+{- function isKeyPressed -}+{#fun sfml_kbd_isKeyPressed as isKeyPressed +{ cIntFromEnum `EnumKey' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassKeyboard.hs
@@ -1,65 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassKeyboard.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassKeyboard where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}
-import HGamer3D.Bindings.SFML.EnumKey
-{-# LINE 43 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}
-
-{- function isKeyPressed -}
-isKeyPressed :: EnumKey -> IO (Bool)
-isKeyPressed a1 =
-  let {a1' = cIntFromEnum a1} in 
-  alloca $ \a2' -> 
-  isKeyPressed'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 49 ".\\HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassKeyboard.chs.h sfml_kbd_isKeyPressed"
-  isKeyPressed'_ :: (CInt -> ((Ptr CInt) -> (IO ())))
+ HGamer3D/Bindings/SFML/ClassListener.chs view
@@ -0,0 +1,72 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassListener.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassListener where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+{# import HGamer3D.Bindings.SFML.StructVec3 #}+
+#include "ClassListener.h"
+{- function setGlobalVolume -}+{#fun sfml_lst_setGlobalVolume as setGlobalVolume +{ realToFrac `Float' } -> `()'  #}++{- function getGlobalVolume -}+{#fun sfml_lst_getGlobalVolume as getGlobalVolume +{ alloca- `Float' peekFloatConv*} -> `()'  #}++{- function setPosition -}+{#fun sfml_lst_setPosition as setPosition +{ realToFrac `Float' ,+ realToFrac `Float' ,+ realToFrac `Float' } -> `()'  #}++{- function getPosition -}+{#fun sfml_lst_getPosition as getPosition +{ alloca- `Vec3' peekVec3*} -> `()'  #}++{- function setDirection -}+{#fun sfml_lst_setDirection as setDirection +{ realToFrac `Float' ,+ realToFrac `Float' ,+ realToFrac `Float' } -> `()'  #}++{- function getDirection -}+{#fun sfml_lst_getDirection as getDirection +{ alloca- `Vec3' peekVec3*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassListener.hs
@@ -1,125 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassListener.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassListener where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-import HGamer3D.Bindings.SFML.StructVec3
-{-# LINE 43 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function setGlobalVolume -}
-setGlobalVolume :: Float -> IO ()
-setGlobalVolume a1 =
-  let {a1' = realToFrac a1} in 
-  setGlobalVolume'_ a1' >>= \res ->
-  return ()
-{-# LINE 48 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function getGlobalVolume -}
-getGlobalVolume :: IO (Float)
-getGlobalVolume =
-  alloca $ \a1' -> 
-  getGlobalVolume'_ a1' >>= \res ->
-  peekFloatConv  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 52 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function setPosition -}
-setPosition :: Float -> Float -> Float -> IO ()
-setPosition a1 a2 a3 =
-  let {a1' = realToFrac a1} in 
-  let {a2' = realToFrac a2} in 
-  let {a3' = realToFrac a3} in 
-  setPosition'_ a1' a2' a3' >>= \res ->
-  return ()
-{-# LINE 58 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function getPosition -}
-getPosition :: IO (Vec3)
-getPosition =
-  alloca $ \a1' -> 
-  getPosition'_ a1' >>= \res ->
-  peekVec3  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 62 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function setDirection -}
-setDirection :: Float -> Float -> Float -> IO ()
-setDirection a1 a2 a3 =
-  let {a1' = realToFrac a1} in 
-  let {a2' = realToFrac a2} in 
-  let {a3' = realToFrac a3} in 
-  setDirection'_ a1' a2' a3' >>= \res ->
-  return ()
-{-# LINE 68 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-{- function getDirection -}
-getDirection :: IO (Vec3)
-getDirection =
-  alloca $ \a1' -> 
-  getDirection'_ a1' >>= \res ->
-  peekVec3  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 72 ".\\HGamer3D\\Bindings\\SFML\\ClassListener.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_setGlobalVolume"
-  setGlobalVolume'_ :: (CFloat -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_getGlobalVolume"
-  getGlobalVolume'_ :: ((Ptr CFloat) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_setPosition"
-  setPosition'_ :: (CFloat -> (CFloat -> (CFloat -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_getPosition"
-  getPosition'_ :: ((Vec3Ptr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_setDirection"
-  setDirection'_ :: (CFloat -> (CFloat -> (CFloat -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassListener.chs.h sfml_lst_getDirection"
-  getDirection'_ :: ((Vec3Ptr) -> (IO ()))
+ HGamer3D/Bindings/SFML/ClassMouse.chs view
@@ -0,0 +1,49 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassMouse.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassMouse where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+{# import HGamer3D.Bindings.SFML.EnumMouseButton #}+
+#include "ClassMouse.h"
+{- function isButtonPressed -}+{#fun sfml_mse_isButtonPressed as isButtonPressed +{ cIntFromEnum `EnumMouseButton' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassMouse.hs
@@ -1,65 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassMouse.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassMouse where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}
-import HGamer3D.Bindings.SFML.EnumMouseButton
-{-# LINE 43 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}
-
-{- function isButtonPressed -}
-isButtonPressed :: EnumMouseButton -> IO (Bool)
-isButtonPressed a1 =
-  let {a1' = cIntFromEnum a1} in 
-  alloca $ \a2' -> 
-  isButtonPressed'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 49 ".\\HGamer3D\\Bindings\\SFML\\ClassMouse.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassMouse.chs.h sfml_mse_isButtonPressed"
-  isButtonPressed'_ :: (CInt -> ((Ptr CInt) -> (IO ())))
+ HGamer3D/Bindings/SFML/ClassMouseHG3D.chs view
@@ -0,0 +1,48 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassMouseHG3D.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassMouseHG3D where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+
+#include "ClassMouseHG3D.h"
+{- function getPosition -}+{#fun sfml_mshg_getPosition as getPosition +{ alloca- `Int' peekIntConv*,+ alloca- `Int' peekIntConv*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassMouseHG3D.hs
@@ -1,64 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassMouseHG3D.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassMouseHG3D where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs" #-}
-
-{- function getPosition -}
-getPosition :: IO (Int, Int)
-getPosition =
-  alloca $ \a1' -> 
-  alloca $ \a2' -> 
-  getPosition'_ a1' a2' >>= \res ->
-  peekIntConv  a1'>>= \a1'' -> 
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a1'', a2'')
-{-# LINE 48 ".\\HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassMouseHG3D.chs.h sfml_mshg_getPosition"
-  getPosition'_ :: ((Ptr CInt) -> ((Ptr CInt) -> (IO ())))
+ HGamer3D/Bindings/SFML/ClassMusic.chs view
@@ -0,0 +1,57 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassMusic.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassMusic where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+
+#include "ClassMusic.h"
+{- function Music -}+{#fun sfml_msc_construct as new +{ alloca- `HG3DClass' peek*} -> `()'  #}++{- function ~Music -}+{#fun sfml_msc_destruct as delete +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function openFromFile -}+{#fun sfml_msc_openFromFile as openFromFile +{ withHG3DClass* `HG3DClass' ,+ withCString* `String' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassMusic.hs
@@ -1,87 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassMusic.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassMusic where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-
-{- function Music -}
-new :: IO (HG3DClass)
-new =
-  alloca $ \a1' -> 
-  new'_ a1' >>= \res ->
-  peek  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 47 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-
-{- function ~Music -}
-delete :: HG3DClass -> IO ()
-delete a1 =
-  withHG3DClass a1 $ \a1' -> 
-  delete'_ a1' >>= \res ->
-  return ()
-{-# LINE 51 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-
-{- function openFromFile -}
-openFromFile :: HG3DClass -> String -> IO (Bool)
-openFromFile a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  withCString a2 $ \a2' -> 
-  alloca $ \a3' -> 
-  openFromFile'_ a1' a2' a3' >>= \res ->
-  peekBoolUtil  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 57 ".\\HGamer3D\\Bindings\\SFML\\ClassMusic.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassMusic.chs.h sfml_msc_construct"
-  new'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassMusic.chs.h sfml_msc_destruct"
-  delete'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassMusic.chs.h sfml_msc_openFromFile"
-  openFromFile'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> ((Ptr CInt) -> (IO ()))))
+ HGamer3D/Bindings/SFML/ClassPtr.chs view
@@ -0,0 +1,62 @@+{-# LANGUAGE EmptyDataDecls #-}+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassPtr.chs
+
+-- Class Ptr Utilities+
+module HGamer3D.Bindings.SFML.ClassPtr where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+
+#include "ClassPtr.h"
+{- class ClassMouseHG3D -}+{#pointer *ClassMouseHG3D as ClassMouseHG3D#}+{- class ClassJoystick -}+{#pointer *ClassJoystick as ClassJoystick#}+{- class ClassKeyboard -}+{#pointer *ClassKeyboard as ClassKeyboard#}+{- class ClassListener -}+{#pointer *ClassListener as ClassListener#}+{- class ClassMouse -}+{#pointer *ClassMouse as ClassMouse#}+{- class ClassMusic -}+{#pointer *ClassMusic as ClassMusic#}+{- class ClassSound -}+{#pointer *ClassSound as ClassSound#}+{- class ClassSoundBuffer -}+{#pointer *ClassSoundBuffer as ClassSoundBuffer#}+{- class ClassSoundSource -}+{#pointer *ClassSoundSource as ClassSoundSource#}+{- class ClassSoundStream -}+{#pointer *ClassSoundStream as ClassSoundStream#}
− HGamer3D/Bindings/SFML/ClassPtr.hs
@@ -1,76 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassPtr.chs
-
--- Class Ptr Utilities
-
-module HGamer3D.Bindings.SFML.ClassPtr where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-
-{- class ClassMouseHG3D -}
-type ClassMouseHG3D = Ptr (())
-{-# LINE 44 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassJoystick -}
-type ClassJoystick = Ptr (())
-{-# LINE 46 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassKeyboard -}
-type ClassKeyboard = Ptr (())
-{-# LINE 48 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassListener -}
-type ClassListener = Ptr (())
-{-# LINE 50 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassMouse -}
-type ClassMouse = Ptr (())
-{-# LINE 52 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassMusic -}
-type ClassMusic = Ptr (())
-{-# LINE 54 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassSound -}
-type ClassSound = Ptr (())
-{-# LINE 56 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassSoundBuffer -}
-type ClassSoundBuffer = Ptr (())
-{-# LINE 58 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassSoundSource -}
-type ClassSoundSource = Ptr (())
-{-# LINE 60 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
-{- class ClassSoundStream -}
-type ClassSoundStream = Ptr (())
-{-# LINE 62 ".\\HGamer3D\\Bindings\\SFML\\ClassPtr.chs" #-}
+ HGamer3D/Bindings/SFML/ClassSound.chs view
@@ -0,0 +1,82 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassSound.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassSound where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+
+#include "ClassSound.h"
+{- function Sound -}+{#fun sfml_snd_construct as new +{ alloca- `HG3DClass' peek*} -> `()'  #}++{- function ~Sound -}+{#fun sfml_snd_destruct as delete +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function play -}+{#fun sfml_snd_play as play +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function pause -}+{#fun sfml_snd_pause as pause +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function stop -}+{#fun sfml_snd_stop as stop +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function setBuffer -}+{#fun sfml_snd_setBuffer as setBuffer +{ withHG3DClass* `HG3DClass' ,+ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function setLoop -}+{#fun sfml_snd_setLoop as setLoop +{ withHG3DClass* `HG3DClass' ,+ fromBool `Bool' } -> `()'  #}++{- function getLoop -}+{#fun sfml_snd_getLoop as getLoop +{ withHG3DClass* `HG3DClass' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function resetBuffer -}+{#fun sfml_snd_resetBuffer as resetBuffer +{ withHG3DClass* `HG3DClass' } -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassSound.hs
@@ -1,154 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassSound.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassSound where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function Sound -}
-new :: IO (HG3DClass)
-new =
-  alloca $ \a1' -> 
-  new'_ a1' >>= \res ->
-  peek  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 47 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function ~Sound -}
-delete :: HG3DClass -> IO ()
-delete a1 =
-  withHG3DClass a1 $ \a1' -> 
-  delete'_ a1' >>= \res ->
-  return ()
-{-# LINE 51 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function play -}
-play :: HG3DClass -> IO ()
-play a1 =
-  withHG3DClass a1 $ \a1' -> 
-  play'_ a1' >>= \res ->
-  return ()
-{-# LINE 55 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function pause -}
-pause :: HG3DClass -> IO ()
-pause a1 =
-  withHG3DClass a1 $ \a1' -> 
-  pause'_ a1' >>= \res ->
-  return ()
-{-# LINE 59 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function stop -}
-stop :: HG3DClass -> IO ()
-stop a1 =
-  withHG3DClass a1 $ \a1' -> 
-  stop'_ a1' >>= \res ->
-  return ()
-{-# LINE 63 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function setBuffer -}
-setBuffer :: HG3DClass -> HG3DClass -> IO ()
-setBuffer a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  withHG3DClass a2 $ \a2' -> 
-  setBuffer'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 68 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function setLoop -}
-setLoop :: HG3DClass -> Bool -> IO ()
-setLoop a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = fromBool a2} in 
-  setLoop'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 73 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function getLoop -}
-getLoop :: HG3DClass -> IO (Bool)
-getLoop a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getLoop'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 78 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-{- function resetBuffer -}
-resetBuffer :: HG3DClass -> IO ()
-resetBuffer a1 =
-  withHG3DClass a1 $ \a1' -> 
-  resetBuffer'_ a1' >>= \res ->
-  return ()
-{-# LINE 82 ".\\HGamer3D\\Bindings\\SFML\\ClassSound.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_construct"
-  new'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_destruct"
-  delete'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_play"
-  play'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_pause"
-  pause'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_stop"
-  stop'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_setBuffer"
-  setBuffer'_ :: ((HG3DClassPtr) -> ((HG3DClassPtr) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_setLoop"
-  setLoop'_ :: ((HG3DClassPtr) -> (CInt -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_getLoop"
-  getLoop'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSound.chs.h sfml_snd_resetBuffer"
-  resetBuffer'_ :: ((HG3DClassPtr) -> (IO ()))
+ HGamer3D/Bindings/SFML/ClassSoundBuffer.chs view
@@ -0,0 +1,73 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassSoundBuffer.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassSoundBuffer where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+
+#include "ClassSoundBuffer.h"
+{- function SoundBuffer -}+{#fun sfml_snbf_construct as new +{ alloca- `HG3DClass' peek*} -> `()'  #}++{- function ~SoundBuffer -}+{#fun sfml_snbf_destruct as delete +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function loadFromFile -}+{#fun sfml_snbf_loadFromFile as loadFromFile +{ withHG3DClass* `HG3DClass' ,+ withCString* `String' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function saveToFile -}+{#fun sfml_snbf_saveToFile as saveToFile +{ withHG3DClass* `HG3DClass' ,+ withCString* `String' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function getSampleRate -}+{#fun sfml_snbf_getSampleRate as getSampleRate +{ withHG3DClass* `HG3DClass' ,+ alloca- `Int' peekIntConv*} -> `()'  #}++{- function getChannelCount -}+{#fun sfml_snbf_getChannelCount as getChannelCount +{ withHG3DClass* `HG3DClass' ,+ alloca- `Int' peekIntConv*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassSoundBuffer.hs
@@ -1,127 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassSoundBuffer.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassSoundBuffer where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function SoundBuffer -}
-new :: IO (HG3DClass)
-new =
-  alloca $ \a1' -> 
-  new'_ a1' >>= \res ->
-  peek  a1'>>= \a1'' -> 
-  return (a1'')
-{-# LINE 47 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function ~SoundBuffer -}
-delete :: HG3DClass -> IO ()
-delete a1 =
-  withHG3DClass a1 $ \a1' -> 
-  delete'_ a1' >>= \res ->
-  return ()
-{-# LINE 51 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function loadFromFile -}
-loadFromFile :: HG3DClass -> String -> IO (Bool)
-loadFromFile a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  withCString a2 $ \a2' -> 
-  alloca $ \a3' -> 
-  loadFromFile'_ a1' a2' a3' >>= \res ->
-  peekBoolUtil  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 57 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function saveToFile -}
-saveToFile :: HG3DClass -> String -> IO (Bool)
-saveToFile a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  withCString a2 $ \a2' -> 
-  alloca $ \a3' -> 
-  saveToFile'_ a1' a2' a3' >>= \res ->
-  peekBoolUtil  a3'>>= \a3'' -> 
-  return (a3'')
-{-# LINE 63 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function getSampleRate -}
-getSampleRate :: HG3DClass -> IO (Int)
-getSampleRate a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getSampleRate'_ a1' a2' >>= \res ->
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 68 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-{- function getChannelCount -}
-getChannelCount :: HG3DClass -> IO (Int)
-getChannelCount a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getChannelCount'_ a1' a2' >>= \res ->
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 73 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_construct"
-  new'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_destruct"
-  delete'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_loadFromFile"
-  loadFromFile'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> ((Ptr CInt) -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_saveToFile"
-  saveToFile'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> ((Ptr CInt) -> (IO ()))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_getSampleRate"
-  getSampleRate'_ :: ((HG3DClassPtr) -> ((Ptr CUInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundBuffer.chs.h sfml_snbf_getChannelCount"
-  getChannelCount'_ :: ((HG3DClassPtr) -> ((Ptr CUInt) -> (IO ())))
+ HGamer3D/Bindings/SFML/ClassSoundSource.chs view
@@ -0,0 +1,110 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassSoundSource.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassSoundSource where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+{# import HGamer3D.Bindings.SFML.StructVec3 #}+
+#include "ClassSoundSource.h"
+{- function ~SoundSource -}+{#fun sfml_snsr_destruct as delete +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function setPitch -}+{#fun sfml_snsr_setPitch as setPitch +{ withHG3DClass* `HG3DClass' ,+ realToFrac `Float' } -> `()'  #}++{- function setVolume -}+{#fun sfml_snsr_setVolume as setVolume +{ withHG3DClass* `HG3DClass' ,+ realToFrac `Float' } -> `()'  #}++{- function setPosition -}+{#fun sfml_snsr_setPosition as setPosition +{ withHG3DClass* `HG3DClass' ,+ realToFrac `Float' ,+ realToFrac `Float' ,+ realToFrac `Float' } -> `()'  #}++{- function setRelativeToListener -}+{#fun sfml_snsr_setRelativeToListener as setRelativeToListener +{ withHG3DClass* `HG3DClass' ,+ fromBool `Bool' } -> `()'  #}++{- function setMinDistance -}+{#fun sfml_snsr_setMinDistance as setMinDistance +{ withHG3DClass* `HG3DClass' ,+ realToFrac `Float' } -> `()'  #}++{- function setAttenuation -}+{#fun sfml_snsr_setAttenuation as setAttenuation +{ withHG3DClass* `HG3DClass' ,+ realToFrac `Float' } -> `()'  #}++{- function getPitch -}+{#fun sfml_snsr_getPitch as getPitch +{ withHG3DClass* `HG3DClass' ,+ alloca- `Float' peekFloatConv*} -> `()'  #}++{- function getVolume -}+{#fun sfml_snsr_getVolume as getVolume +{ withHG3DClass* `HG3DClass' ,+ alloca- `Float' peekFloatConv*} -> `()'  #}++{- function getPosition -}+{#fun sfml_snsr_getPosition as getPosition +{ withHG3DClass* `HG3DClass' ,+ alloca- `Vec3' peekVec3*} -> `()'  #}++{- function isRelativeToListener -}+{#fun sfml_snsr_isRelativeToListener as isRelativeToListener +{ withHG3DClass* `HG3DClass' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}++{- function getMinDistance -}+{#fun sfml_snsr_getMinDistance as getMinDistance +{ withHG3DClass* `HG3DClass' ,+ alloca- `Float' peekFloatConv*} -> `()'  #}++{- function getAttenuation -}+{#fun sfml_snsr_getAttenuation as getAttenuation +{ withHG3DClass* `HG3DClass' ,+ alloca- `Float' peekFloatConv*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassSoundSource.hs
@@ -1,215 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassSoundSource.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassSoundSource where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-import HGamer3D.Bindings.SFML.StructVec3
-{-# LINE 43 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function ~SoundSource -}
-delete :: HG3DClass -> IO ()
-delete a1 =
-  withHG3DClass a1 $ \a1' -> 
-  delete'_ a1' >>= \res ->
-  return ()
-{-# LINE 48 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setPitch -}
-setPitch :: HG3DClass -> Float -> IO ()
-setPitch a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = realToFrac a2} in 
-  setPitch'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 53 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setVolume -}
-setVolume :: HG3DClass -> Float -> IO ()
-setVolume a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = realToFrac a2} in 
-  setVolume'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 58 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setPosition -}
-setPosition :: HG3DClass -> Float -> Float -> Float -> IO ()
-setPosition a1 a2 a3 a4 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = realToFrac a2} in 
-  let {a3' = realToFrac a3} in 
-  let {a4' = realToFrac a4} in 
-  setPosition'_ a1' a2' a3' a4' >>= \res ->
-  return ()
-{-# LINE 65 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setRelativeToListener -}
-setRelativeToListener :: HG3DClass -> Bool -> IO ()
-setRelativeToListener a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = fromBool a2} in 
-  setRelativeToListener'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 70 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setMinDistance -}
-setMinDistance :: HG3DClass -> Float -> IO ()
-setMinDistance a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = realToFrac a2} in 
-  setMinDistance'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 75 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function setAttenuation -}
-setAttenuation :: HG3DClass -> Float -> IO ()
-setAttenuation a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = realToFrac a2} in 
-  setAttenuation'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 80 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function getPitch -}
-getPitch :: HG3DClass -> IO (Float)
-getPitch a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getPitch'_ a1' a2' >>= \res ->
-  peekFloatConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 85 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function getVolume -}
-getVolume :: HG3DClass -> IO (Float)
-getVolume a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getVolume'_ a1' a2' >>= \res ->
-  peekFloatConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 90 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function getPosition -}
-getPosition :: HG3DClass -> IO (Vec3)
-getPosition a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getPosition'_ a1' a2' >>= \res ->
-  peekVec3  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 95 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function isRelativeToListener -}
-isRelativeToListener :: HG3DClass -> IO (Bool)
-isRelativeToListener a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  isRelativeToListener'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 100 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function getMinDistance -}
-getMinDistance :: HG3DClass -> IO (Float)
-getMinDistance a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getMinDistance'_ a1' a2' >>= \res ->
-  peekFloatConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 105 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-{- function getAttenuation -}
-getAttenuation :: HG3DClass -> IO (Float)
-getAttenuation a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getAttenuation'_ a1' a2' >>= \res ->
-  peekFloatConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 110 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_destruct"
-  delete'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setPitch"
-  setPitch'_ :: ((HG3DClassPtr) -> (CFloat -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setVolume"
-  setVolume'_ :: ((HG3DClassPtr) -> (CFloat -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setPosition"
-  setPosition'_ :: ((HG3DClassPtr) -> (CFloat -> (CFloat -> (CFloat -> (IO ())))))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setRelativeToListener"
-  setRelativeToListener'_ :: ((HG3DClassPtr) -> (CInt -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setMinDistance"
-  setMinDistance'_ :: ((HG3DClassPtr) -> (CFloat -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_setAttenuation"
-  setAttenuation'_ :: ((HG3DClassPtr) -> (CFloat -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_getPitch"
-  getPitch'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_getVolume"
-  getVolume'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_getPosition"
-  getPosition'_ :: ((HG3DClassPtr) -> ((Vec3Ptr) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_isRelativeToListener"
-  isRelativeToListener'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_getMinDistance"
-  getMinDistance'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundSource.chs.h sfml_snsr_getAttenuation"
-  getAttenuation'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ())))
+ HGamer3D/Bindings/SFML/ClassSoundStream.chs view
@@ -0,0 +1,79 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- ClassSoundStream.chs
+
+-- +
+module HGamer3D.Bindings.SFML.ClassSoundStream where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+{# import HGamer3D.Bindings.SFML.Utils #}+{# import HGamer3D.Bindings.SFML.ClassPtr #}+{# import HGamer3D.Bindings.SFML.StructHG3DClass #}+
+#include "ClassSoundStream.h"
+{- function ~SoundStream -}+{#fun sfml_snst_destruct as delete +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function play -}+{#fun sfml_snst_play as play +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function pause -}+{#fun sfml_snst_pause as pause +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function stop -}+{#fun sfml_snst_stop as stop +{ withHG3DClass* `HG3DClass' } -> `()'  #}++{- function getChannelCount -}+{#fun sfml_snst_getChannelCount as getChannelCount +{ withHG3DClass* `HG3DClass' ,+ alloca- `Int' peekIntConv*} -> `()'  #}++{- function getSampleRate -}+{#fun sfml_snst_getSampleRate as getSampleRate +{ withHG3DClass* `HG3DClass' ,+ alloca- `Int' peekIntConv*} -> `()'  #}++{- function setLoop -}+{#fun sfml_snst_setLoop as setLoop +{ withHG3DClass* `HG3DClass' ,+ fromBool `Bool' } -> `()'  #}++{- function getLoop -}+{#fun sfml_snst_getLoop as getLoop +{ withHG3DClass* `HG3DClass' ,+ alloca- `Bool' peekBoolUtil*} -> `()'  #}+
− HGamer3D/Bindings/SFML/ClassSoundStream.hs
@@ -1,145 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- ClassSoundStream.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.ClassSoundStream where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-import HGamer3D.Bindings.SFML.Utils
-{-# LINE 40 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-import HGamer3D.Bindings.SFML.ClassPtr
-{-# LINE 41 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-import HGamer3D.Bindings.SFML.StructHG3DClass
-{-# LINE 42 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function ~SoundStream -}
-delete :: HG3DClass -> IO ()
-delete a1 =
-  withHG3DClass a1 $ \a1' -> 
-  delete'_ a1' >>= \res ->
-  return ()
-{-# LINE 47 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function play -}
-play :: HG3DClass -> IO ()
-play a1 =
-  withHG3DClass a1 $ \a1' -> 
-  play'_ a1' >>= \res ->
-  return ()
-{-# LINE 51 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function pause -}
-pause :: HG3DClass -> IO ()
-pause a1 =
-  withHG3DClass a1 $ \a1' -> 
-  pause'_ a1' >>= \res ->
-  return ()
-{-# LINE 55 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function stop -}
-stop :: HG3DClass -> IO ()
-stop a1 =
-  withHG3DClass a1 $ \a1' -> 
-  stop'_ a1' >>= \res ->
-  return ()
-{-# LINE 59 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function getChannelCount -}
-getChannelCount :: HG3DClass -> IO (Int)
-getChannelCount a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getChannelCount'_ a1' a2' >>= \res ->
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 64 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function getSampleRate -}
-getSampleRate :: HG3DClass -> IO (Int)
-getSampleRate a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getSampleRate'_ a1' a2' >>= \res ->
-  peekIntConv  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 69 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function setLoop -}
-setLoop :: HG3DClass -> Bool -> IO ()
-setLoop a1 a2 =
-  withHG3DClass a1 $ \a1' -> 
-  let {a2' = fromBool a2} in 
-  setLoop'_ a1' a2' >>= \res ->
-  return ()
-{-# LINE 74 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-{- function getLoop -}
-getLoop :: HG3DClass -> IO (Bool)
-getLoop a1 =
-  withHG3DClass a1 $ \a1' -> 
-  alloca $ \a2' -> 
-  getLoop'_ a1' a2' >>= \res ->
-  peekBoolUtil  a2'>>= \a2'' -> 
-  return (a2'')
-{-# LINE 79 ".\\HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs" #-}
-
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_destruct"
-  delete'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_play"
-  play'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_pause"
-  pause'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_stop"
-  stop'_ :: ((HG3DClassPtr) -> (IO ()))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_getChannelCount"
-  getChannelCount'_ :: ((HG3DClassPtr) -> ((Ptr CUInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_getSampleRate"
-  getSampleRate'_ :: ((HG3DClassPtr) -> ((Ptr CUInt) -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_setLoop"
-  setLoop'_ :: ((HG3DClassPtr) -> (CInt -> (IO ())))
-
-foreign import ccall safe "HGamer3D\\Bindings\\SFML\\ClassSoundStream.chs.h sfml_snst_getLoop"
-  getLoop'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ())))
+ HGamer3D/Bindings/SFML/EnumJoystickAxis.chs view
@@ -0,0 +1,41 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- EnumJoystickAxis.chs
+
+-- +
+module HGamer3D.Bindings.SFML.EnumJoystickAxis where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "EnumJoystickAxis.h"
+{#enum EnumJoystickAxis {} deriving (Eq)#}
− HGamer3D/Bindings/SFML/EnumJoystickAxis.hs
@@ -1,53 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\EnumJoystickAxis.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- EnumJoystickAxis.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.EnumJoystickAxis where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-data EnumJoystickAxis = JoystickAxisX
-                      | JoystickAxisY
-                      | JoystickAxisZ
-                      | JoystickAxisR
-                      | JoystickAxisU
-                      | JoystickAxisV
-                      | JoystickAxisPovX
-                      | JoystickAxisPovY
-                      deriving (Enum,Eq)
+ HGamer3D/Bindings/SFML/EnumKey.chs view
@@ -0,0 +1,41 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- EnumKey.chs
+
+-- +
+module HGamer3D.Bindings.SFML.EnumKey where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "EnumKey.h"
+{#enum EnumKey {} deriving (Eq)#}
− HGamer3D/Bindings/SFML/EnumKey.hs
@@ -1,147 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\EnumKey.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- EnumKey.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.EnumKey where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-data EnumKey = KeyA
-             | KeyB
-             | KeyC
-             | KeyD
-             | KeyE
-             | KeyF
-             | KeyG
-             | KeyH
-             | KeyI
-             | KeyJ
-             | KeyK
-             | KeyL
-             | KeyM
-             | KeyN
-             | KeyO
-             | KeyP
-             | KeyQ
-             | KeyR
-             | KeyS
-             | KeyT
-             | KeyU
-             | KeyV
-             | KeyW
-             | KeyX
-             | KeyY
-             | KeyZ
-             | KeyNum0
-             | KeyNum1
-             | KeyNum2
-             | KeyNum3
-             | KeyNum4
-             | KeyNum5
-             | KeyNum6
-             | KeyNum7
-             | KeyNum8
-             | KeyNum9
-             | KeyEscape
-             | KeyLControl
-             | KeyLShift
-             | KeyLAlt
-             | KeyLSystem
-             | KeyRControl
-             | KeyRShift
-             | KeyRAlt
-             | KeyRSystem
-             | KeyMenu
-             | KeyLBracket
-             | KeyRBracket
-             | KeySemiColon
-             | KeyComma
-             | KeyPeriod
-             | KeyQuote
-             | KeySlash
-             | KeyBackSlash
-             | KeyTilde
-             | KeyEqual
-             | KeyDash
-             | KeySpace
-             | KeyReturn
-             | KeyBack
-             | KeyTab
-             | KeyPageUp
-             | KeyPageDown
-             | KeyEnd
-             | KeyHome
-             | KeyInsert
-             | KeyDelete
-             | KeyAdd
-             | KeySubtract
-             | KeyMultiply
-             | KeyDivide
-             | KeyLeft
-             | KeyRight
-             | KeyUp
-             | KeyDown
-             | KeyNumpad0
-             | KeyNumpad1
-             | KeyNumpad2
-             | KeyNumpad3
-             | KeyNumpad4
-             | KeyNumpad5
-             | KeyNumpad6
-             | KeyNumpad7
-             | KeyNumpad8
-             | KeyNumpad9
-             | KeyF1
-             | KeyF2
-             | KeyF3
-             | KeyF4
-             | KeyF5
-             | KeyF6
-             | KeyF7
-             | KeyF8
-             | KeyF9
-             | KeyF10
-             | KeyF11
-             | KeyF12
-             | KeyF13
-             | KeyF14
-             | KeyF15
-             | KeyPause
-             | KeyKeyCount
-             deriving (Enum,Eq)
+ HGamer3D/Bindings/SFML/EnumMouseButton.chs view
@@ -0,0 +1,41 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- EnumMouseButton.chs
+
+-- +
+module HGamer3D.Bindings.SFML.EnumMouseButton where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "EnumMouseButton.h"
+{#enum EnumMouseButton {} deriving (Eq)#}
− HGamer3D/Bindings/SFML/EnumMouseButton.hs
@@ -1,51 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\EnumMouseButton.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- EnumMouseButton.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.EnumMouseButton where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-data EnumMouseButton = MouseButtonLeft
-                     | MouseButtonRight
-                     | MouseButtonMiddle
-                     | MouseButtonXButton1
-                     | MouseButtonXButton2
-                     | MouseButtonButtonCount
-                     deriving (Enum,Eq)
+ HGamer3D/Bindings/SFML/EnumSoundSourceStatus.chs view
@@ -0,0 +1,41 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- EnumSoundSourceStatus.chs
+
+-- +
+module HGamer3D.Bindings.SFML.EnumSoundSourceStatus where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "EnumSoundSourceStatus.h"
+{#enum EnumSoundSourceStatus {} deriving (Eq)#}
− HGamer3D/Bindings/SFML/EnumSoundSourceStatus.hs
@@ -1,48 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\EnumSoundSourceStatus.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- EnumSoundSourceStatus.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.EnumSoundSourceStatus where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-data EnumSoundSourceStatus = SoundSourceStatusStopped
-                           | SoundSourceStatusPaused
-                           | SoundSourceStatusPlaying
-                           deriving (Enum,Eq)
+ HGamer3D/Bindings/SFML/StructHG3DClass.chs view
@@ -0,0 +1,52 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- StructHG3DClass.chs
+
+-- +
+module HGamer3D.Bindings.SFML.StructHG3DClass where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "StructHG3DClass.h"
++import Data.Bits+import HGamer3D.Data.HG3DClass++{#pointer *hg3dclass_struct as HG3DClassPtr -> HG3DClass #}++withHG3DClass :: HG3DClass -> (HG3DClassPtr -> IO b) -> IO b+withHG3DClass = with++peekHG3DClass :: HG3DClassPtr -> IO HG3DClass+peekHG3DClass = peek+
− HGamer3D/Bindings/SFML/StructHG3DClass.hs
@@ -1,57 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\StructHG3DClass.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- StructHG3DClass.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.StructHG3DClass where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-
-import Data.Bits
-import HGamer3D.Data.HG3DClass
-
-type HG3DClassPtr = Ptr (HG3DClass)
-{-# LINE 46 ".\\HGamer3D\\Bindings\\SFML\\StructHG3DClass.chs" #-}
-
-withHG3DClass :: HG3DClass -> (HG3DClassPtr -> IO b) -> IO b
-withHG3DClass = with
-
-peekHG3DClass :: HG3DClassPtr -> IO HG3DClass
-peekHG3DClass = peek
-
+ HGamer3D/Bindings/SFML/StructVec3.chs view
@@ -0,0 +1,72 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- StructVec3.chs
+
+-- +
+module HGamer3D.Bindings.SFML.StructVec3 where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "StructVec3.h"
++import Data.Bits+import HGamer3D.Data.Vector++newtype Vector3f = Vector3f Vec3++instance Storable Vector3f where+  alignment _ = alignment (undefined :: CDouble)+  sizeOf _ = {#sizeof vector3f_struct#}+  peek p = do+	x <- {#get vector3f_struct.x #} p+	y <- {#get vector3f_struct.y #} p+	z <- {#get vector3f_struct.z #} p+	let v = Vector3f (Vec3 (realToFrac x) (realToFrac y) (realToFrac z))+	return v+  poke p (Vector3f (Vec3 x y z)) = do+    {#set vector3f_struct.x #} p (realToFrac x)+    {#set vector3f_struct.y #} p (realToFrac  y)+    {#set vector3f_struct.z #} p (realToFrac  z)+    +type Vector3fPtr = Ptr (Vector3f)++{#pointer *vector3f_struct as Vec3Ptr -> Vec3 #}++withVec3 :: Vec3 -> (Vec3Ptr -> IO b) -> IO b+withVec3 v f = with v' f' where+     v' = Vector3f v+     f' p = f (castPtr p)+peekVec3 p = do+   (Vector3f v3) <- peek ((castPtr p)::Vector3fPtr)+   return v3+
− HGamer3D/Bindings/SFML/StructVec3.hs
@@ -1,78 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\StructVec3.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- StructVec3.chs
-
--- 
-
-module HGamer3D.Bindings.SFML.StructVec3 where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-
-import Data.Bits
-import HGamer3D.Data.Vector
-
-newtype Vector3f = Vector3f Vec3
-
-instance Storable Vector3f where
-  alignment _ = alignment (undefined :: CDouble)
-  sizeOf _ = 12
-{-# LINE 50 ".\\HGamer3D\\Bindings\\SFML\\StructVec3.chs" #-}
-  peek p = do
-	x <- (\ptr -> do {peekByteOff ptr 0 ::IO CFloat}) p
-	y <- (\ptr -> do {peekByteOff ptr 4 ::IO CFloat}) p
-	z <- (\ptr -> do {peekByteOff ptr 8 ::IO CFloat}) p
-	let v = Vector3f (Vec3 (realToFrac x) (realToFrac y) (realToFrac z))
-	return v
-  poke p (Vector3f (Vec3 x y z)) = do
-    (\ptr val -> do {pokeByteOff ptr 0 (val::CFloat)}) p (realToFrac x)
-    (\ptr val -> do {pokeByteOff ptr 4 (val::CFloat)}) p (realToFrac  y)
-    (\ptr val -> do {pokeByteOff ptr 8 (val::CFloat)}) p (realToFrac  z)
-    
-type Vector3fPtr = Ptr (Vector3f)
-
-type Vec3Ptr = Ptr (Vec3)
-{-# LINE 64 ".\\HGamer3D\\Bindings\\SFML\\StructVec3.chs" #-}
-
-withVec3 :: Vec3 -> (Vec3Ptr -> IO b) -> IO b
-withVec3 v f = with v' f' where
-     v' = Vector3f v
-     f' p = f (castPtr p)
-peekVec3 p = do
-   (Vector3f v3) <- peek ((castPtr p)::Vector3fPtr)
-   return v3
-
+ HGamer3D/Bindings/SFML/Utils.chs view
@@ -0,0 +1,132 @@+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE TypeSynonymInstances #-}
+
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +
+-- (c) 2011-2014 Peter Althainz
+-- 
+-- Licensed under the Apache License, Version 2.0 (the "License");
+-- you may not use this file except in compliance with the License.
+-- You may obtain a copy of the License at
+-- 
+--     http://www.apache.org/licenses/LICENSE-2.0
+-- 
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+-- +
+
+-- Utils.hs
+
+-- Marshalling Utilities+
+module HGamer3D.Bindings.SFML.Utils where
+
+import Foreign
+import Foreign.Ptr
+import Foreign.C
+
+import HGamer3D.Data.HG3DClass
+import HGamer3D.Data.Vector
+import HGamer3D.Data.Colour
+import HGamer3D.Data.Angle
+
+
+#include "StructHG3DClass.h"
++import Control.Monad (liftM)++-- Strings with explicit length+--+withCStringLenIntConv :: Num n => String -> ((CString, n) -> IO a) -> IO a+withCStringLenIntConv s f    = withCStringLen s $ \(p, n) -> f (p, fromIntegral n)++peekCStringLenIntConv :: Integral n => (CString, n) -> IO String+peekCStringLenIntConv (s, n) = peekCStringLen (s, fromIntegral n)++-- Marshalling of numerals+--++withIntConv   :: (Storable b, Integral a, Integral b) +              => a -> (Ptr b -> IO c) -> IO c+withIntConv    = with . fromIntegral++withFloatConv :: (Storable b, RealFloat a, RealFloat b) +              => a -> (Ptr b -> IO c) -> IO c+withFloatConv  = with . realToFrac++peekIntConv   :: (Storable a, Integral a, Integral b) +              => Ptr a -> IO b+peekIntConv    = liftM fromIntegral . peek++peekFloatConv :: (Storable a, RealFloat a, RealFloat b) +              => Ptr a -> IO b+peekFloatConv  = liftM realToFrac . peek+++-- String Conversion functions+--++withCUString b f = withCWString b (f . castPtr)+peekCUString = peekCWString . castPtr+alloc64k = allocaBytes (1024 * 64)++-- c2hs replacements of utility functions, to get rid of annoying c2hs+-- deprecated messages++-- Passing Enums++cIntFromEnum :: Enum a => a -> CInt+cIntFromEnum = cIntConv . fromEnum++cIntToEnum :: Enum a => CInt -> a+cIntToEnum = toEnum . cIntConv+++-- Passing Booleans by reference+--++withBoolUtil :: (Integral a, Storable a) => Bool -> (Ptr a -> IO b) -> IO b+withBoolUtil  = with . fromBool++peekBoolUtil :: (Integral a, Storable a) => Ptr a -> IO Bool+peekBoolUtil  = liftM toBool . peek+++-- Passing enums by reference+--++withEnumUtil :: (Enum a, Integral b, Storable b) => a -> (Ptr b -> IO c) -> IO c+withEnumUtil  = with . cFromEnum++peekEnumUtil :: (Enum a, Integral b, Storable b) => Ptr b -> IO a+peekEnumUtil  = liftM cToEnum . peek++-- Conversion routines+-- -------------------++-- |Integral conversion+--+cIntConv :: (Integral a, Integral b) => a -> b+cIntConv  = fromIntegral++-- |Floating conversion+--+cFloatConv :: (RealFloat a, RealFloat b) => a -> b+cFloatConv  = realToFrac++-- |Convert a C enumeration to Haskell.+--+cToEnum :: (Integral i, Enum e) => i -> e+cToEnum  = toEnum . fromIntegral++-- |Convert a Haskell enumeration to C.+--+cFromEnum :: (Enum e, Integral i) => e -> i+cFromEnum  = fromIntegral . fromEnum+
− HGamer3D/Bindings/SFML/Utils.hs
@@ -1,136 +0,0 @@--- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell)
--- Edit the ORIGNAL .chs file instead!
-
-
-{-# LINE 1 ".\\HGamer3D\\Bindings\\SFML\\Utils.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-}
-{-# LANGUAGE TypeSynonymInstances #-}
-
--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
-
--- (c) 2011, 2012 Peter Althainz
--- 
--- Licensed under the Apache License, Version 2.0 (the "License");
--- you may not use this file except in compliance with the License.
--- You may obtain a copy of the License at
--- 
---     http://www.apache.org/licenses/LICENSE-2.0
--- 
--- Unless required by applicable law or agreed to in writing, software
--- distributed under the License is distributed on an "AS IS" BASIS,
--- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
--- See the License for the specific language governing permissions and
--- limitations under the License.
--- 
-
-
--- Utils.hs
-
--- Marshalling Utilities
-
-module HGamer3D.Bindings.SFML.Utils where
-
-import Foreign
-import Foreign.Ptr
-import Foreign.C
-
-import HGamer3D.Data.HG3DClass
-import HGamer3D.Data.Vector
-import HGamer3D.Data.Colour
-import HGamer3D.Data.Angle
-
-
-
-import Control.Monad (liftM)
-
--- Strings with explicit length
---
-withCStringLenIntConv :: Num n => String -> ((CString, n) -> IO a) -> IO a
-withCStringLenIntConv s f    = withCStringLen s $ \(p, n) -> f (p, fromIntegral n)
-
-peekCStringLenIntConv :: Integral n => (CString, n) -> IO String
-peekCStringLenIntConv (s, n) = peekCStringLen (s, fromIntegral n)
-
--- Marshalling of numerals
---
-
-withIntConv   :: (Storable b, Integral a, Integral b) 
-              => a -> (Ptr b -> IO c) -> IO c
-withIntConv    = with . fromIntegral
-
-withFloatConv :: (Storable b, RealFloat a, RealFloat b) 
-              => a -> (Ptr b -> IO c) -> IO c
-withFloatConv  = with . realToFrac
-
-peekIntConv   :: (Storable a, Integral a, Integral b) 
-              => Ptr a -> IO b
-peekIntConv    = liftM fromIntegral . peek
-
-peekFloatConv :: (Storable a, RealFloat a, RealFloat b) 
-              => Ptr a -> IO b
-peekFloatConv  = liftM realToFrac . peek
-
-
--- String Conversion functions
---
-
-withCUString b f = withCWString b (f . castPtr)
-peekCUString = peekCWString . castPtr
-alloc64k = allocaBytes (1024 * 64)
-
--- c2hs replacements of utility functions, to get rid of annoying c2hs
--- deprecated messages
-
--- Passing Enums
-
-cIntFromEnum :: Enum a => a -> CInt
-cIntFromEnum = cIntConv . fromEnum
-
-cIntToEnum :: Enum a => CInt -> a
-cIntToEnum = toEnum . cIntConv
-
-
--- Passing Booleans by reference
---
-
-withBoolUtil :: (Integral a, Storable a) => Bool -> (Ptr a -> IO b) -> IO b
-withBoolUtil  = with . fromBool
-
-peekBoolUtil :: (Integral a, Storable a) => Ptr a -> IO Bool
-peekBoolUtil  = liftM toBool . peek
-
-
--- Passing enums by reference
---
-
-withEnumUtil :: (Enum a, Integral b, Storable b) => a -> (Ptr b -> IO c) -> IO c
-withEnumUtil  = with . cFromEnum
-
-peekEnumUtil :: (Enum a, Integral b, Storable b) => Ptr b -> IO a
-peekEnumUtil  = liftM cToEnum . peek
-
--- Conversion routines
--- -------------------
-
--- |Integral conversion
---
-cIntConv :: (Integral a, Integral b) => a -> b
-cIntConv  = fromIntegral
-
--- |Floating conversion
---
-cFloatConv :: (RealFloat a, RealFloat b) => a -> b
-cFloatConv  = realToFrac
-
--- |Convert a C enumeration to Haskell.
---
-cToEnum :: (Integral i, Enum e) => i -> e
-cToEnum  = toEnum . fromIntegral
-
--- |Convert a Haskell enumeration to C.
---
-cFromEnum :: (Enum e, Integral i) => e -> i
-cFromEnum  = fromIntegral . fromEnum
-
LICENSE view
@@ -1,4 +1,4 @@-(c) 2011, 2012 Peter Althainz
+(c) 2011-2014 Peter Althainz
 
 Licensed under the Apache License, Version 2.0 (the "License");
 you may not use this file except in compliance with the License.
Setup.hs view
@@ -1,8 +1,7 @@--- This source file is part of HGamer3D
--- (A project to enable 3D game development in Haskell)
--- For the latest info, see http://www.althainz.de/HGamer3D.html
--- 
--- (c) 2011, 2012 Peter Althainz
+-- This source file is part of HGamer3D, a project to enable 3D game development 
+-- in Haskell. For the latest info, see http://www.hgamer3d.org .
+-- +-- (c) 2011-2014 Peter Althainz
 -- 
 -- Licensed under the Apache License, Version 2.0 (the "License");
 -- you may not use this file except in compliance with the License.
@@ -15,7 +14,7 @@ -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 -- See the License for the specific language governing permissions and
 -- limitations under the License.
--- 
+--  -- Setup.hs
 
 import Distribution.Simple
− include/ClassJoystick.h
@@ -1,50 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassJoystick.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassJoystick
-#define _DEFINED_HG3D_ClassJoystick
-
-#include "ClassPtr.h"
-#include "EnumJoystickAxis.h"
-
-
-// Check if a joystick is connected. 
-void sfml_jst_isConnected(unsigned int joystick_c, int * result_c);
-
-// Return the number of buttons supported by a joystick. 
-void sfml_jst_getButtonCount(unsigned int joystick_c, unsigned int * result_c);
-
-// Check if a joystick supports a given axis. 
-void sfml_jst_hasAxis(unsigned int joystick_c, enum EnumJoystickAxis axis_c, int * result_c);
-
-// Check if a joystick button is pressed. 
-void sfml_jst_isButtonPressed(unsigned int joystick_c, unsigned int button_c, int * result_c);
-
-// Get the current position of a joystick axis. 
-void sfml_jst_getAxisPosition(unsigned int joystick_c, enum EnumJoystickAxis axis_c, float * result_c);
-
-// Update the states of all joysticks. 
-void sfml_jst_update();
-
-#endif 
− include/ClassKeyboard.h
@@ -1,35 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassKeyboard.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassKeyboard
-#define _DEFINED_HG3D_ClassKeyboard
-
-#include "ClassPtr.h"
-#include "EnumKey.h"
-
-
-// Check if a key is pressed. 
-void sfml_kbd_isKeyPressed(enum EnumKey key_c, int * result_c);
-
-#endif 
− include/ClassListener.h
@@ -1,50 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassListener.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassListener
-#define _DEFINED_HG3D_ClassListener
-
-#include "ClassPtr.h"
-#include "StructVec3.h"
-
-
-// Change the global volume of all the sounds and musics. 
-void sfml_lst_setGlobalVolume(float volume_c);
-
-// Get the current value of the global volume. 
-void sfml_lst_getGlobalVolume(float * result_c);
-
-// Set the position of the listener in the scene. 
-void sfml_lst_setPosition(float x_c, float y_c, float z_c);
-
-// Get the current position of the listener in the scene. 
-void sfml_lst_getPosition(struct vector3f_struct * result_c);
-
-// Set the orientation of the listener in the scene. 
-void sfml_lst_setDirection(float x_c, float y_c, float z_c);
-
-// Get the current orientation of the listener in the scene. 
-void sfml_lst_getDirection(struct vector3f_struct * result_c);
-
-#endif 
− include/ClassMouse.h
@@ -1,35 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassMouse.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassMouse
-#define _DEFINED_HG3D_ClassMouse
-
-#include "ClassPtr.h"
-#include "EnumMouseButton.h"
-
-
-// Check if a mouse button is pressed. 
-void sfml_mse_isButtonPressed(enum EnumMouseButton button_c, int * result_c);
-
-#endif 
− include/ClassMouseHG3D.h
@@ -1,34 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassMouseHG3D.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassMouseHG3D
-#define _DEFINED_HG3D_ClassMouseHG3D
-
-#include "ClassPtr.h"
-
-
-// 
-void sfml_mshg_getPosition(int * x_c, int * y_c);
-
-#endif 
− include/ClassMusic.h
@@ -1,40 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassMusic.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassMusic
-#define _DEFINED_HG3D_ClassMusic
-
-#include "ClassPtr.h"
-
-
-// Default constructor. 
-void sfml_msc_construct(struct hg3dclass_struct * result_c);
-
-// Destructor. 
-void sfml_msc_destruct(struct hg3dclass_struct * thisclass_c);
-
-// Open a music from an audio file. 
-void sfml_msc_openFromFile(struct hg3dclass_struct * thisclass_c, char * filename_c, int * result_c);
-
-#endif 
− include/ClassPtr.h
@@ -1,69 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassPtr.h
-
-// Here are the methods defined, which do the class pointer
-// marshalling and the casting of subclasses to higher classes
-
-#include "wchar.h"
-
-
-#ifndef CLASSPTR_INCLUDE_H
-#define CLASSPTR_INCLUDE_H
-
-typedef struct hg3dclass_struct {
-	void *ptr;
-	void *fptr;
-} hg3dclass_struct;
-
-void *getHG3DClassPtr(hg3dclass_struct inSt, const char* className);
-
-
-typedef void ClassMouseHG3D; 
-hg3dclass_struct getHG3DClass_MouseHG3D(void *ptrIn);
-
-typedef void ClassJoystick; 
-hg3dclass_struct getHG3DClass_Joystick(void *ptrIn);
-
-typedef void ClassKeyboard; 
-hg3dclass_struct getHG3DClass_Keyboard(void *ptrIn);
-
-typedef void ClassListener; 
-hg3dclass_struct getHG3DClass_Listener(void *ptrIn);
-
-typedef void ClassMouse; 
-hg3dclass_struct getHG3DClass_Mouse(void *ptrIn);
-
-typedef void ClassMusic; 
-hg3dclass_struct getHG3DClass_Music(void *ptrIn);
-
-typedef void ClassSound; 
-hg3dclass_struct getHG3DClass_Sound(void *ptrIn);
-
-typedef void ClassSoundBuffer; 
-hg3dclass_struct getHG3DClass_SoundBuffer(void *ptrIn);
-
-typedef void ClassSoundSource; 
-hg3dclass_struct getHG3DClass_SoundSource(void *ptrIn);
-
-typedef void ClassSoundStream; 
-hg3dclass_struct getHG3DClass_SoundStream(void *ptrIn);
-
-#endif
− include/ClassSound.h
@@ -1,59 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassSound.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassSound
-#define _DEFINED_HG3D_ClassSound
-
-#include "ClassPtr.h"
-#include "ClassSoundBuffer.h"
-
-
-// Default constructor. 
-void sfml_snd_construct(struct hg3dclass_struct * result_c);
-
-// Destructor. 
-void sfml_snd_destruct(struct hg3dclass_struct * thisclass_c);
-
-// Start or resume playing the sound. 
-void sfml_snd_play(struct hg3dclass_struct * thisclass_c);
-
-// Pause the sound. 
-void sfml_snd_pause(struct hg3dclass_struct * thisclass_c);
-
-// Stop playing the sound. 
-void sfml_snd_stop(struct hg3dclass_struct * thisclass_c);
-
-// Set the source buffer containing the audio data to play. 
-void sfml_snd_setBuffer(struct hg3dclass_struct * thisclass_c, struct hg3dclass_struct * buffer_c);
-
-// Set whether or not the sound should loop after reaching the end. 
-void sfml_snd_setLoop(struct hg3dclass_struct * thisclass_c, int loop_c);
-
-// Tell whether or not the sound is in loop mode. 
-void sfml_snd_getLoop(struct hg3dclass_struct * thisclass_c, int * result_c);
-
-// Reset the internal buffer of the sound. 
-void sfml_snd_resetBuffer(struct hg3dclass_struct * thisclass_c);
-
-#endif 
− include/ClassSoundBuffer.h
@@ -1,49 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassSoundBuffer.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassSoundBuffer
-#define _DEFINED_HG3D_ClassSoundBuffer
-
-#include "ClassPtr.h"
-
-
-// Default constructor. 
-void sfml_snbf_construct(struct hg3dclass_struct * result_c);
-
-// Destructor. 
-void sfml_snbf_destruct(struct hg3dclass_struct * thisclass_c);
-
-// Load the sound buffer from a file. 
-void sfml_snbf_loadFromFile(struct hg3dclass_struct * thisclass_c, char * filename_c, int * result_c);
-
-// Save the sound buffer to an audio file. 
-void sfml_snbf_saveToFile(struct hg3dclass_struct * thisclass_c, char * filename_c, int * result_c);
-
-// Get the sample rate of the sound. 
-void sfml_snbf_getSampleRate(struct hg3dclass_struct * thisclass_c, unsigned int * result_c);
-
-// Get the number of channels used by the sound. 
-void sfml_snbf_getChannelCount(struct hg3dclass_struct * thisclass_c, unsigned int * result_c);
-
-#endif 
− include/ClassSoundSource.h
@@ -1,71 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassSoundSource.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassSoundSource
-#define _DEFINED_HG3D_ClassSoundSource
-
-#include "ClassPtr.h"
-#include "StructVec3.h"
-
-
-// Destructor. 
-void sfml_snsr_destruct(struct hg3dclass_struct * thisclass_c);
-
-// Set the pitch of the sound. 
-void sfml_snsr_setPitch(struct hg3dclass_struct * thisclass_c, float pitch_c);
-
-// Set the volume of the sound. 
-void sfml_snsr_setVolume(struct hg3dclass_struct * thisclass_c, float volume_c);
-
-// Set the 3D position of the sound in the audio scene. 
-void sfml_snsr_setPosition(struct hg3dclass_struct * thisclass_c, float x_c, float y_c, float z_c);
-
-// Make the sound's position relative to the listener or absolute. 
-void sfml_snsr_setRelativeToListener(struct hg3dclass_struct * thisclass_c, int relative_c);
-
-// Set the minimum distance of the sound. 
-void sfml_snsr_setMinDistance(struct hg3dclass_struct * thisclass_c, float distance_c);
-
-// Set the attenuation factor of the sound. 
-void sfml_snsr_setAttenuation(struct hg3dclass_struct * thisclass_c, float attenuation_c);
-
-// Get the pitch of the sound. 
-void sfml_snsr_getPitch(struct hg3dclass_struct * thisclass_c, float * result_c);
-
-// Get the volume of the sound. 
-void sfml_snsr_getVolume(struct hg3dclass_struct * thisclass_c, float * result_c);
-
-// Get the 3D position of the sound in the audio scene. 
-void sfml_snsr_getPosition(struct hg3dclass_struct * thisclass_c, struct vector3f_struct * result_c);
-
-// Tell whether the sound's position is relative to the listener or is absolute. 
-void sfml_snsr_isRelativeToListener(struct hg3dclass_struct * thisclass_c, int * result_c);
-
-// Get the minimum distance of the sound. 
-void sfml_snsr_getMinDistance(struct hg3dclass_struct * thisclass_c, float * result_c);
-
-// Get the attenuation factor of the sound. 
-void sfml_snsr_getAttenuation(struct hg3dclass_struct * thisclass_c, float * result_c);
-
-#endif 
− include/ClassSoundStream.h
@@ -1,55 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// ClassSoundStream.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_ClassSoundStream
-#define _DEFINED_HG3D_ClassSoundStream
-
-#include "ClassPtr.h"
-
-
-// Destructor. 
-void sfml_snst_destruct(struct hg3dclass_struct * thisclass_c);
-
-// Start or resume playing the audio stream. 
-void sfml_snst_play(struct hg3dclass_struct * thisclass_c);
-
-// Pause the audio stream. 
-void sfml_snst_pause(struct hg3dclass_struct * thisclass_c);
-
-// Stop playing the audio stream. 
-void sfml_snst_stop(struct hg3dclass_struct * thisclass_c);
-
-// Return the number of channels of the stream. 
-void sfml_snst_getChannelCount(struct hg3dclass_struct * thisclass_c, unsigned int * result_c);
-
-// Get the stream sample rate of the stream. 
-void sfml_snst_getSampleRate(struct hg3dclass_struct * thisclass_c, unsigned int * result_c);
-
-// Set whether or not the stream should loop after reaching the end. 
-void sfml_snst_setLoop(struct hg3dclass_struct * thisclass_c, int loop_c);
-
-// Tell whether or not the stream is in loop mode. 
-void sfml_snst_getLoop(struct hg3dclass_struct * thisclass_c, int * result_c);
-
-#endif 
− include/EnumJoystickAxis.h
@@ -1,40 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// EnumJoystickAxis.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_EnumJoystickAxis
-#define _DEFINED_HG3D_EnumJoystickAxis
-
-
-enum EnumJoystickAxis
-{
-  JoystickAxisX, // The X axis. 
-  JoystickAxisY, // The Y axis. 
-  JoystickAxisZ, // The Z axis. 
-  JoystickAxisR, // The R axis. 
-  JoystickAxisU, // The U axis. 
-  JoystickAxisV, // The V axis. 
-  JoystickAxisPovX, // The X axis of the point-of-view hat. 
-  JoystickAxisPovY // The Y axis of the point-of-view hat. 
-};
-#endif 
− include/EnumKey.h
@@ -1,134 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// EnumKey.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_EnumKey
-#define _DEFINED_HG3D_EnumKey
-
-
-enum EnumKey
-{
-  KeyA, // The A key. 
-  KeyB, // The B key. 
-  KeyC, // The C key. 
-  KeyD, // The D key. 
-  KeyE, // The E key. 
-  KeyF, // The F key. 
-  KeyG, // The G key. 
-  KeyH, // The H key. 
-  KeyI, // The I key. 
-  KeyJ, // The J key. 
-  KeyK, // The K key. 
-  KeyL, // The L key. 
-  KeyM, // The M key. 
-  KeyN, // The N key. 
-  KeyO, // The O key. 
-  KeyP, // The P key. 
-  KeyQ, // The Q key. 
-  KeyR, // The R key. 
-  KeyS, // The S key. 
-  KeyT, // The T key. 
-  KeyU, // The U key. 
-  KeyV, // The V key. 
-  KeyW, // The W key. 
-  KeyX, // The X key. 
-  KeyY, // The Y key. 
-  KeyZ, // The Z key. 
-  KeyNum0, // The 0 key. 
-  KeyNum1, // The 1 key. 
-  KeyNum2, // The 2 key. 
-  KeyNum3, // The 3 key. 
-  KeyNum4, // The 4 key. 
-  KeyNum5, // The 5 key. 
-  KeyNum6, // The 6 key. 
-  KeyNum7, // The 7 key. 
-  KeyNum8, // The 8 key. 
-  KeyNum9, // The 9 key. 
-  KeyEscape, // The Escape key. 
-  KeyLControl, // The left Control key. 
-  KeyLShift, // The left Shift key. 
-  KeyLAlt, // The left Alt key. 
-  KeyLSystem, // The left OS specific key: window (Windows and Linux), apple (MacOS X), ... 
-  KeyRControl, // The right Control key. 
-  KeyRShift, // The right Shift key. 
-  KeyRAlt, // The right Alt key. 
-  KeyRSystem, // The right OS specific key: window (Windows and Linux), apple (MacOS X), ... 
-  KeyMenu, // The Menu key. 
-  KeyLBracket, // The [ key. 
-  KeyRBracket, // The ] key. 
-  KeySemiColon, // The ; key. 
-  KeyComma, // The , key. 
-  KeyPeriod, // The . key. 
-  KeyQuote, // The ' key. 
-  KeySlash, // The / key. 
-  KeyBackSlash, // The \ key. 
-  KeyTilde, // The ~ key. 
-  KeyEqual, // The = key. 
-  KeyDash, // The - key. 
-  KeySpace, // The Space key. 
-  KeyReturn, // The Return key. 
-  KeyBack, // The Backspace key. 
-  KeyTab, // The Tabulation key. 
-  KeyPageUp, // The Page up key. 
-  KeyPageDown, // The Page down key. 
-  KeyEnd, // The End key. 
-  KeyHome, // The Home key. 
-  KeyInsert, // The Insert key. 
-  KeyDelete, // The Delete key. 
-  KeyAdd, // 
-  KeySubtract, // 
-  KeyMultiply, // 
-  KeyDivide, // / 
-  KeyLeft, // Left arrow. 
-  KeyRight, // Right arrow. 
-  KeyUp, // Up arrow. 
-  KeyDown, // Down arrow. 
-  KeyNumpad0, // The numpad 0 key. 
-  KeyNumpad1, // The numpad 1 key. 
-  KeyNumpad2, // The numpad 2 key. 
-  KeyNumpad3, // The numpad 3 key. 
-  KeyNumpad4, // The numpad 4 key. 
-  KeyNumpad5, // The numpad 5 key. 
-  KeyNumpad6, // The numpad 6 key. 
-  KeyNumpad7, // The numpad 7 key. 
-  KeyNumpad8, // The numpad 8 key. 
-  KeyNumpad9, // The numpad 9 key. 
-  KeyF1, // The F1 key. 
-  KeyF2, // The F2 key. 
-  KeyF3, // The F3 key. 
-  KeyF4, // The F4 key. 
-  KeyF5, // The F5 key. 
-  KeyF6, // The F6 key. 
-  KeyF7, // The F7 key. 
-  KeyF8, // The F8 key. 
-  KeyF9, // The F8 key. 
-  KeyF10, // The F10 key. 
-  KeyF11, // The F11 key. 
-  KeyF12, // The F12 key. 
-  KeyF13, // The F13 key. 
-  KeyF14, // The F14 key. 
-  KeyF15, // The F15 key. 
-  KeyPause, // The Pause key. 
-  KeyKeyCount // Keep last 
-};
-#endif 
− include/EnumMouseButton.h
@@ -1,38 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// EnumMouseButton.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_EnumMouseButton
-#define _DEFINED_HG3D_EnumMouseButton
-
-
-enum EnumMouseButton
-{
-  MouseButtonLeft, // The left mouse button. 
-  MouseButtonRight, // The right mouse button. 
-  MouseButtonMiddle, // The middle (wheel) mouse button. 
-  MouseButtonXButton1, // The first extra mouse button. 
-  MouseButtonXButton2, // The second extra mouse button. 
-  MouseButtonButtonCount // Keep last 
-};
-#endif 
− include/EnumSoundSourceStatus.h
@@ -1,35 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// EnumSoundSourceStatus.h
-
-// 
-
-#include "wchar.h"
-#ifndef _DEFINED_HG3D_EnumSoundSourceStatus
-#define _DEFINED_HG3D_EnumSoundSourceStatus
-
-
-enum EnumSoundSourceStatus
-{
-  SoundSourceStatusStopped, // Sound
-  SoundSourceStatusPaused, // Sound
-  SoundSourceStatusPlaying // Sound
-};
-#endif 
+ include/MouseHG3D.h view
@@ -0,0 +1,18 @@+// MouseHG3D - special mouse class to get a specialized way to obtain
+// the mouse coordinates
+
+#include <SFML/System/Vector2.hpp>
+#include <SFML/Window/Mouse.hpp>
+
+class MouseHG3D : sf::Mouse {
+	
+	public:
+		static void getPosition(int &x, int &y) {
+			sf::Vector2i vi = sf::Vector2i();
+			vi = sf::Mouse::getPosition();
+			x = vi.x;
+			y = vi.y;
+		};
+	
+};
+
− include/SFMLDllDefines.h
@@ -1,41 +0,0 @@-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-
-// SFMLDllDefines.h
-
-#ifndef _HGamer3DSFML020_DLLDEFINES_H_
-#define _HGamer3DSFML020_DLLDEFINES_H_
-
-/* Cmake will define HGamer3DSFML020_EXPORTS on Windows when it
-configures to build a shared library. If you are going to use
-another build system on windows or create the visual studio
-projects by hand you need to define MyLibrary_EXPORTS when
-building a DLL on windows.
-*/
-
-// We are using the Visual Studio Compiler and building Shared libraries
-
-#if (defined (_WIN32)) && !(defined (__GNUC__)) 
-  #if defined(HGamer3DSFML020_EXPORTS)
-    #define  SFML_LIB_EXPORT __declspec(dllexport)
-  #else
-    #define  SFML_LIB_EXPORT __declspec(dllimport)
-  #endif /* HGamer3DSFML020_EXPORTS */
-#else /* defined (_WIN32) */
- #define SFML_LIB_EXPORT
-#endif
-
-#endif /* _HGamer3DSFML020_DLLDEFINES_H_ */
− include/StructHG3DClass.h
@@ -1,30 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// StructHG3DClass.h
-
-// 
-
-#include "wchar.h"
-
-
-typedef struct hg3dclass_struct {
-	void *ptr;
-	void *fptr;
-} hg3dclass_struct;
− include/StructVec3.h
@@ -1,36 +0,0 @@-// This source file is part of HGamer3D
-// (A project to enable 3D game development in Haskell)
-// For the latest info, see http://www.althainz.de/HGamer3D.html
-// 
-// (c) 2011, 2012 Peter Althainz
-// 
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-// 
-//     http://www.apache.org/licenses/LICENSE-2.0
-// 
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// 
-
-// StructVec3.h
-
-// 
-
-#include "wchar.h"
-
-
-#ifndef _INC_STRUCT_VECTOR3F
-#define _INC_STRUCT_VECTOR3F
-
-typedef struct vector3f_struct {
-	float x;
-	float y;
-	float z;
-} vector3f_struct;
-
-#endif
+ include/hg3dstruct.h view
@@ -0,0 +1,4 @@+typedef struct hg3dclass_struct {+	void *ptr;+	void *fptr;+} hg3dclass_struct;
+ include/vector2fstruct.h view
@@ -0,0 +1,4 @@+typedef struct vector2f_struct {
+	float x;
+	float y;
+} vector2f_struct;
+ include/vector2istruct.h view
@@ -0,0 +1,4 @@+typedef struct vector2i_struct {
+	int x;
+	int y;
+} vector2i_struct;
+ include/vector3fstruct.h view
@@ -0,0 +1,5 @@+typedef struct vector3f_struct {
+	float x;
+	float y;
+	float z;
+} vector3f_struct;
+ include/vector3istruct.h view
@@ -0,0 +1,5 @@+typedef struct vector3i_struct {
+	int x;
+	int y;
+	int z;
+} vector3i_struct;