handa-opengl-0.1.6.1: Utility functions for OpenGL and GLUT

Copyright(c) 2015 Brian W Bush
LicenseMIT
MaintainerBrian W Bush <consult@brianwbush.info>
StabilityStable
PortabilityPortable
Safe HaskellNone
LanguageHaskell2010

Graphics.Rendering.Handa.Shape

Contents

Description

Functions and types for managing shapes represented as vertex buffer objects (VBOs).

Synopsis

Types

data Shape Source #

A shape stored as a vertex buffer object (VBO).

Functions

makeShape Source #

Arguments

:: Storable a 
=> NumComponents

The number of components per vertex.

-> DataType

The data type for the vertices' components.

-> PrimitiveMode

The type of primitive.

-> [a]

The vertices.

-> IO ()

The display action to be executed prior to rendering the shape.

-> IO Shape

An action for the shape.

Construct a shape.

remakeShape Source #

Arguments

:: Storable a 
=> Shape

The shape.

-> [a]

The replacement vertices.

-> IO Shape

An action for the updated shape.

Reconstruct a shape by replacing its vertices.

drawShape Source #

Arguments

:: Shape

The shape.

-> IO ()

An action to render the shape, also executing its prior actions before rendering it.

Render a shape.