repa-bytestring-2.1.0.1: Conversions between Repa Arrays and ByteStrings.

Data.Array.Repa.ByteString

Description

Conversions between Repa Arrays and ByteStrings.

Synopsis

Documentation

toByteString :: Shape sh => Array sh Word8 -> ByteStringSource

Copy an Array to a (strict) ByteString.

fromByteString :: Shape sh => sh -> ByteString -> Array sh Word8Source

Copy a (strict) ByteString to a new Array. The given array extent must match the length of the ByteString, else error.

copyFromPtrWord8 :: Shape sh => sh -> Ptr Word8 -> IO (Array sh Word8)Source

Copy some data from somewhere into a new Array.

copyToPtrWord8 :: Shape sh => Ptr Word8 -> Array sh Word8 -> IO ()Source

Copy array data somewhere.s