cuda-0.7.0.0: FFI binding to the CUDA interface for programming NVIDIA GPUs

Copyright[2009..2014] Trevor L. McDonell
LicenseBSD
Safe HaskellNone
LanguageHaskell98

Foreign.CUDA.Runtime.Texture

Contents

Description

Texture references

Synopsis

Texture Reference Management

data Texture Source

Constructors

Texture 

Fields

normalised :: !Bool

access texture using normalised coordinates [0.0,1.0)

filtering :: !FilterMode
 
addressing :: !(AddressMode, AddressMode, AddressMode)
 
format :: !FormatDesc
 

data FormatKind Source

Texture channel format kind

Constructors

Signed 
Unsigned 
Float 
None 

Instances

data AddressMode Source

Constructors

Wrap 
Clamp 
Mirror 
Border 

Instances

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).

Constructors

FormatDesc 

Fields

depth :: !(Int, Int, Int, Int)
 
kind :: !FormatKind
 

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.