Copyright | (c) [2009..2012] Trevor L. McDonell |
---|---|
License | BSD |
Safe Haskell | None |
Language | Haskell98 |
Texture references
- data Texture = Texture {
- normalised :: !Bool
- filtering :: !FilterMode
- addressing :: !(AddressMode, AddressMode, AddressMode)
- format :: !FormatDesc
- data FormatKind
- data AddressMode
- data FilterMode
- data FormatDesc = FormatDesc {}
- bind :: String -> Texture -> DevicePtr a -> Int64 -> IO ()
- bind2D :: String -> Texture -> DevicePtr a -> (Int, Int) -> Int64 -> IO ()
Texture Reference Management
Texture | |
|
data FormatKind Source
Texture channel format kind
Enum FormatKind | Texture addressing mode |
Eq FormatKind | |
Show FormatKind |
data AddressMode Source
Enum AddressMode | Texture filtering mode |
Eq AddressMode | |
Show AddressMode |
data FormatDesc Source
A description of how memory read through the texture cache should be interpreted, including the kind of data and the number of bits of each component (x,y,z and w, respectively).
bind :: String -> Texture -> DevicePtr a -> Int64 -> IO () Source
Bind the memory area associated with the device pointer to a texture reference given by the named symbol. Any previously bound references are unbound.
bind2D :: String -> Texture -> DevicePtr a -> (Int, Int) -> Int64 -> IO () Source
Bind the two-dimensional memory area to the texture reference associated with the given symbol. The size of the area is constrained by (width,height) in texel units, and the row pitch in bytes. Any previously bound references are unbound.