arrayfire-0.4.0.0: Haskell bindings to the ArrayFire general-purpose GPU library

CopyrightDavid Johnson (c) 2019-2020
LicenseBSD 3
MaintainerDavid Johnson <djohnson.m@gmail.com>
StabilityExperimental
PortabilityGHC
Safe HaskellNone
LanguageHaskell2010

ArrayFire.Graphics

Description

 
Synopsis

Documentation

createWindow Source #

Arguments

:: Int

width

-> Int

height

-> String

title

-> IO Window

Window handle

Create window

ArrayFire Docs

>>> window <- createWindow 800 600 "New Chart"

setPosition Source #

Arguments

:: Window

Window handle

-> Int

Horizontal start coordinate

-> Int

Vertical start coordinate

-> IO () 

Sets Window position

ArrayFire Docs

>>> window <- createWindow 800 600 "New Chart"
>>> setPosition window 800 600

setTitle Source #

Arguments

:: Window

Window handle

-> String

title

-> IO () 

Sets Window title

ArrayFire Docs

>>> window <- createWindow 800 600 "New Chart"
>>> setTitle window "window title"

setSize Source #

Arguments

:: Window

Window handle

-> Int

target width of the window

-> Int

target height of the window

-> IO () 

Sets Window size

ArrayFire Docs

>>> window <- createWindow 800 600 "New Chart"
>>> setSize window 800 600

drawImage Source #

Arguments

:: Window

Window handle

-> Array a

Image

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw an image onto a Window

ArrayFire Docs

>>> drawImage window ('constant' \@'Int' 1) ('Cell' 10 10 "test" 'ColorMapSpectrum')

drawPlot Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis data points

-> Array a

is an Array with the y-axis data points

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a plot onto a Window

ArrayFire Docs

>>> drawPlot window ('constant' \@'Int' 1) ('constant' \@'Int' 1) ('Cell' 10 10 "test" 'ColorMapSpectrum')
  • Note* X and Y should be vectors.

drawPlot3 Source #

Arguments

:: Window

the window handle

-> Array a

is an af_array or matrix with the xyz-values of the points

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a plot onto a Window

ArrayFire Docs

  • Note* P should be a 3n x 1 vector or one of a 3xn or nx3 matrices.

drawPlotNd Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array or matrix with the xyz-values of the points

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a plot onto a Window

ArrayFire Docs

  • Note* in must be 2d and of the form [n, order], where order is either 2 or 3. If order is 2, then chart is 2D and if order is 3, then chart is 3D.

drawPlot2d Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis data points

-> Array a

is an Array with the y-axis data points

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a plot onto a Window

ArrayFire Docs

  • Note* X and Y should be vectors.

drawPlot3d Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis data points

-> Array a

is an Array with the y-axis data points

-> Array a

is an Array with the z-axis data points

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a 3D plot onto a Window

ArrayFire Docs

  • Note* X, Y and Z should be vectors.

drawScatter Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis data points

-> Array a

is an Array with the y-axis data points

-> MarkerType

enum specifying which marker to use in the scatter plot

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a scatter plot onto a Window

ArrayFire Docs

  • Note* X and Y should be vectors.

drawScatter3 Source #

Arguments

:: Window

is the window handle

-> Array a

is an af_array or matrix with the xyz-values of the points

-> MarkerType

is an af_marker_type enum specifying which marker to use in the scatter plot

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a scatter plot onto a Window

ArrayFire Docs

  • Note* X and Y should be vectors.

drawScatterNd Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array or matrix with the xyz-values of the points

-> MarkerType

is an af_marker_type enum specifying which marker to use in the scatter plot

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a scatter plot onto a Window

ArrayFire Docs

  • Note* in must be 2d and of the form [n, order], where order is either 2 or 3. If order is 2, then chart is 2D and if order is 3, then chart is 3D.

drawScatter2d Source #

Arguments

:: Window

is the window handle

-> Array a

is an af_array with the x-axis data points

-> Array a

is an af_array with the y-axis data points

-> MarkerType

is an af_marker_type enum specifying which marker to use in the scatter plot

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a scatter plot onto a Window

ArrayFire Docs

  • Note* in must be 2d and of the form [n, order], where order is either 2 or 3. If order is 2, then chart is 2D and if order is 3, then chart is 3D.

drawScatter3d Source #

Arguments

:: Window

is the window handle

-> Array a

is an af_array with the x-axis data points

-> Array a

is an af_array with the y-axis data points

-> Array a

is an af_array with the z-axis data points

-> MarkerType

is an af_marker_type enum specifying which marker to use in the scatter plot

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a scatter plot onto a Window

ArrayFire Docs

  • Note* X, Y and Z should be vectors.

drawHistogram Source #

Arguments

:: Window

is the window handle

-> Array a

is the data frequency af_array

-> Double

is the value of the minimum data point of the array whose histogram(X) is going to be rendered.

-> Double

is the value of the maximum data point of the array whose histogram(X) is going to be rendered.

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a Histogram onto a Window

ArrayFire Docs

  • Note* X should be a vector.

drawSurface Source #

Arguments

:: Window

is the window handle

-> Array a

is an af_array with the x-axis data points

-> Array a

is an af_array with the y-axis data points

-> Array a

is an af_array with the z-axis data points

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Draw a Surface onto a Window

ArrayFire Docs

  • Note* X and Y should be vectors. S should be a 2D array

drawVectorFieldND Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the points

-> Array a

is an Array with the directions

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a Vector Field onto a Window

ArrayFire Docs

  • Note* all the Array inputs should be vectors and the same size

drawVectorField3d Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis points

-> Array a

is an Array with the y-axis points

-> Array a

is an Array with the z-axis points

-> Array a

is an Array with the x-axis directions

-> Array a

is an Array with the y-axis directions

-> Array a

is an Array with the z-axis directions

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Draw a Vector Field onto a Window

ArrayFire Docs

  • Note* all the Array inputs should be vectors and the same size

drawVectorField2d Source #

Arguments

:: Window

is the window handle

-> Array a

is an Array with the x-axis points

-> Array a

is the window handle

-> Array a

is the window handle

-> Array a

is the window handle

-> Cell

is the window handle

-> IO () 

Draw a Vector Field onto a Window

ArrayFire Docs

  • Note* all the Array inputs should be vectors and the same size

grid Source #

Arguments

:: Window

is the window handle

-> Int

is number of rows you want to show in a window

-> Int

is number of coloumns you want to show in a window

-> IO () 

Draw a grid onto a Window

ArrayFire Docs

  • Note* all the Array inputs should be vectors and the same size

setAxesLimitsCompute Source #

Arguments

:: Window

is the window handle

-> Array a

the data to compute the limits for x-axis.

-> Array a

the data to compute the limits for y-axis.

-> Array a

the data to compute the limits for z-axis.

-> Bool

is for using the exact min/max values from x, y and z. If exact is false then the most significant digit is rounded up to next power of 2 and the magnitude remains the same.

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Setting axes limits for a histogramplotsurface/vector field.

ArrayFire Docs

  • Note* Set to NULL if the chart is 2D.

setAxesLimits2d Source #

Arguments

:: Window

is the window handle

-> Float

is the minimum on x-axis

-> Float

is the maximum on x-axis

-> Float

is the minimum on y-axis

-> Float

is the maximum on y-axis

-> Bool

is for using the exact min/max values from x, and y. If exact is false then the most significant digit is rounded up to next power of 2 and the magnitude remains the same.

-> Cell

is structure af_cell that has the properties that are used for the current rendering.

-> IO () 

Setting axes limits for a 2D histogramplotsurface/vector field.

ArrayFire Docs

setAxesLimits3d Source #

Arguments

:: Window

is the window handle

-> Float

is the minimum on x-axis

-> Float

is the maximum on x-axis

-> Float

is the minimum on y-axis

-> Float

is the maximum on y-axis

-> Float

is the minimum on z-axis

-> Float

is the maximum on z-axis

-> Bool

is for using the exact min/max values from x, y and z. If exact is false then the most significant digit is rounded up to next power of 2 and the magnitude remains the same.

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Setting axes limits for a 3D histogramplotsurface/vector field.

ArrayFire Docs

setAxesTitles Source #

Arguments

:: Window

is the window handle

-> String

is the name of the x-axis

-> String

is the name of the y-axis

-> String

is the name of the z-axis

-> Cell

is structure Cell that has the properties that are used for the current rendering.

-> IO () 

Setting axes titles

ArrayFire Docs

showWindow Source #

Arguments

:: Window

Window handle

-> IO () 

setVisibility Source #

Arguments

:: Window

Window handle

-> Bool

Set to True to display Window

-> IO () 

Sets Window visibility

ArrayFire Docs