sdl2-2.2.0: Both high- and low-level bindings to the SDL library (version 2.0.4+).

Safe HaskellSafe
LanguageHaskell2010

SDL.Raw.Types

Contents

Synopsis

Type Aliases

Function Types

type AudioCallback = FunPtr (Ptr () -> Ptr Word8 -> CInt -> IO ()) #

type EventFilter = FunPtr (Ptr () -> Ptr Event -> IO CInt) #

type HintCallback = FunPtr (Ptr () -> CString -> CString -> CString -> IO ()) #

type LogOutputFunction = FunPtr (Ptr () -> CInt -> LogPriority -> CString -> IO ()) #

type ThreadFunction = FunPtr (Ptr () -> IO CInt) #

mkAudioCallback :: (Ptr () -> Ptr Word8 -> CInt -> IO ()) -> IO AudioCallback #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

mkEventFilter :: (Ptr () -> Ptr Event -> IO CInt) -> IO EventFilter #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

mkHintCallback :: (Ptr () -> CString -> CString -> CString -> IO ()) -> IO HintCallback #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

mkLogOutputFunction :: (Ptr () -> CInt -> LogPriority -> CString -> IO ()) -> IO LogOutputFunction #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

mkThreadFunction :: (Ptr () -> IO CInt) -> IO ThreadFunction #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

mkTimerCallback :: (Word32 -> Ptr () -> IO Word32) -> IO TimerCallback #

The storage associated with the resulting FunPtr has to be released with freeHaskellFunPtr when it is no longer required.

Common Types

type Cond = Ptr () #

type Cursor = Ptr () #

type GameController = Ptr () #

type GLContext = Ptr () #

type Haptic = Ptr () #

type Joystick = Ptr () #

type Mutex = Ptr () #

type Renderer = Ptr () #

type Sem = Ptr () #

type SpinLock = CInt #

type SysWMinfo = Ptr () #

type SysWMmsg = Ptr () #

type Texture = Ptr () #

type Thread = Ptr () #

type TimerID = CInt #

type TLSID = CUInt #

type TouchID = Int64 #

type Window = Ptr () #

Data Structures

data Atomic #

Constructors

Atomic 

Fields

Instances

data Color #

Constructors

Color 

Fields

Instances

Eq Color # 

Methods

(==) :: Color -> Color -> Bool #

(/=) :: Color -> Color -> Bool #

Show Color # 

Methods

showsPrec :: Int -> Color -> ShowS #

show :: Color -> String #

showList :: [Color] -> ShowS #

Storable Color # 

Methods

sizeOf :: Color -> Int #

alignment :: Color -> Int #

peekElemOff :: Ptr Color -> Int -> IO Color #

pokeElemOff :: Ptr Color -> Int -> Color -> IO () #

peekByteOff :: Ptr b -> Int -> IO Color #

pokeByteOff :: Ptr b -> Int -> Color -> IO () #

peek :: Ptr Color -> IO Color #

poke :: Ptr Color -> Color -> IO () #

data Event #

Constructors

WindowEvent 
KeyboardEvent 
TextEditingEvent 
TextInputEvent 
KeymapChangedEvent 
MouseMotionEvent 
MouseButtonEvent 
MouseWheelEvent 
JoyAxisEvent 
JoyBallEvent 
JoyHatEvent 
JoyButtonEvent 
JoyDeviceEvent 
ControllerAxisEvent 
ControllerButtonEvent 
ControllerDeviceEvent 
AudioDeviceEvent 
QuitEvent 
UserEvent 
SysWMEvent 
TouchFingerEvent 
MultiGestureEvent 
DollarGestureEvent 
DropEvent 
ClipboardUpdateEvent 
UnknownEvent 

Instances

Eq Event # 

Methods

(==) :: Event -> Event -> Bool #

(/=) :: Event -> Event -> Bool #

Show Event # 

Methods

showsPrec :: Int -> Event -> ShowS #

show :: Event -> String #

showList :: [Event] -> ShowS #

Storable Event # 

Methods

sizeOf :: Event -> Int #

alignment :: Event -> Int #

peekElemOff :: Ptr Event -> Int -> IO Event #

pokeElemOff :: Ptr Event -> Int -> Event -> IO () #

peekByteOff :: Ptr b -> Int -> IO Event #

pokeByteOff :: Ptr b -> Int -> Event -> IO () #

peek :: Ptr Event -> IO Event #

poke :: Ptr Event -> Event -> IO () #

data Finger #

Constructors

Finger 

Instances

data HapticEffect #

Constructors

HapticConstant 
HapticPeriodic 
HapticCondition 
HapticRamp 
HapticLeftRight 
HapticCustom 

data Keysym #

Instances

data Point #

Constructors

Point 

Fields

Instances

Eq Point # 

Methods

(==) :: Point -> Point -> Bool #

(/=) :: Point -> Point -> Bool #

Show Point # 

Methods

showsPrec :: Int -> Point -> ShowS #

show :: Point -> String #

showList :: [Point] -> ShowS #

Storable Point # 

Methods

sizeOf :: Point -> Int #

alignment :: Point -> Int #

peekElemOff :: Ptr Point -> Int -> IO Point #

pokeElemOff :: Ptr Point -> Int -> Point -> IO () #

peekByteOff :: Ptr b -> Int -> IO Point #

pokeByteOff :: Ptr b -> Int -> Point -> IO () #

peek :: Ptr Point -> IO Point #

poke :: Ptr Point -> Point -> IO () #

data Rect #

Constructors

Rect 

Fields

Instances

Eq Rect # 

Methods

(==) :: Rect -> Rect -> Bool #

(/=) :: Rect -> Rect -> Bool #

Show Rect # 

Methods

showsPrec :: Int -> Rect -> ShowS #

show :: Rect -> String #

showList :: [Rect] -> ShowS #

Storable Rect # 

Methods

sizeOf :: Rect -> Int #

alignment :: Rect -> Int #

peekElemOff :: Ptr Rect -> Int -> IO Rect #

pokeElemOff :: Ptr Rect -> Int -> Rect -> IO () #

peekByteOff :: Ptr b -> Int -> IO Rect #

pokeByteOff :: Ptr b -> Int -> Rect -> IO () #

peek :: Ptr Rect -> IO Rect #

poke :: Ptr Rect -> Rect -> IO () #

data RWops #

Constructors

RWops 

Fields

Instances

Eq RWops # 

Methods

(==) :: RWops -> RWops -> Bool #

(/=) :: RWops -> RWops -> Bool #

Show RWops # 

Methods

showsPrec :: Int -> RWops -> ShowS #

show :: RWops -> String #

showList :: [RWops] -> ShowS #

Storable RWops # 

Methods

sizeOf :: RWops -> Int #

alignment :: RWops -> Int #

peekElemOff :: Ptr RWops -> Int -> IO RWops #

pokeElemOff :: Ptr RWops -> Int -> RWops -> IO () #

peekByteOff :: Ptr b -> Int -> IO RWops #

pokeByteOff :: Ptr b -> Int -> RWops -> IO () #

peek :: Ptr RWops -> IO RWops #

poke :: Ptr RWops -> RWops -> IO () #