free-game-0.3.0.1: Create graphical applications for free.

Portabilitynon-portable
Stabilityprovisional
MaintainerFumiaki Kinsohita <fumiexcel@gmail.com>
Safe HaskellNone

Graphics.FreeGame.Bitmap

Description

Manipulating bitmaps

Synopsis

Documentation

data Bitmap Source

Concrete bitmap data type

bitmapData :: Bitmap -> Array D DIM3 Word8Source

Bare the Bitmap's internal representation (y * x * ARGB)

bitmapSize :: Bitmap -> (Int, Int)Source

Get the size of the Bitmap.

loadBitmapFromFile :: FilePath -> IO BitmapSource

Create a Bitmap from the given file.

cropBitmapSource

Arguments

:: Bitmap

original bitmap

-> (Int, Int)

width and height

-> (Int, Int)

x and y

-> Bitmap

result

Extract a Bitmap from the specified range.

data Font Source

Font object

loadFont :: FilePath -> Float -> IO FontSource

create a Font from the given file.

charToBitmap :: Font -> (Word8, Word8, Word8) -> Char -> IO (Maybe (Bitmap, Float, Float, Float))Source

render Bitmap of the character by specified Font and color(RGB).