Forge
|
Plot is a line graph to display two dimensional data. More...
#include <plot.h>
Public Member Functions | |
FGAPI | Plot (const unsigned pNumPoints, const dtype pDataType, const ChartType pChartType, const PlotType pPlotType=FG_PLOT_LINE, const MarkerType pMarkerType=FG_MARKER_NONE) |
Creates a Plot object. More... | |
FGAPI | Plot (const Plot &pOther) |
Copy constructor for Plot. More... | |
FGAPI | Plot (const fg_plot pHandle) |
Construct Plot ojbect from fg_plot resource handle. More... | |
FGAPI | ~Plot () |
Plot Destructor. More... | |
FGAPI void | setColor (const forge::Color pColor) |
Set the color of line graph(plot) More... | |
FGAPI void | setColor (const float pRed, const float pGreen, const float pBlue, const float pAlpha) |
Set the color of line graph(plot) More... | |
FGAPI void | setLegend (const char *pLegend) |
Set plot legend. More... | |
FGAPI void | setMarkerSize (const float pMarkerSize) |
Set global marker size. More... | |
FGAPI unsigned | vertices () const |
Get the buffer identifier for vertices. More... | |
FGAPI unsigned | colors () const |
Get the buffer identifier for color values per vertex. More... | |
FGAPI unsigned | alphas () const |
Get the buffer identifier for alpha values per vertex. More... | |
FGAPI unsigned | radii () const |
Get the buffer identifier for per vertex marker sizes. More... | |
FGAPI unsigned | verticesSize () const |
Get the vertex buffer size in bytes. More... | |
FGAPI unsigned | colorsSize () const |
Get the colors buffer size in bytes. More... | |
FGAPI unsigned | alphasSize () const |
Get the alpha values buffer size in bytes. More... | |
FGAPI unsigned | radiiSize () const |
Get the marker sizes buffer size in bytes. More... | |
FGAPI fg_plot | get () const |
Get the handle to internal implementation of plot. More... | |
Plot is a line graph to display two dimensional data.
FGAPI Plot | ( | const unsigned | pNumPoints, |
const dtype | pDataType, | ||
const ChartType | pChartType, | ||
const PlotType | pPlotType = FG_PLOT_LINE , |
||
const MarkerType | pMarkerType = FG_MARKER_NONE |
||
) |
Creates a Plot object.
[in] | pNumPoints | is number of data points to display |
[in] | pDataType | takes one of the values of dtype that indicates the integral data type of plot data |
[in] | pChartType | dictates the dimensionality of the chart |
[in] | pPlotType | dictates the type of plot/graph, it can take one of the values of PlotType |
[in] | pMarkerType | indicates which symbol is rendered as marker. It can take one of the values of MarkerType. |
FGAPI unsigned alphas | ( | ) | const |
Get the buffer identifier for alpha values per vertex.
FGAPI unsigned alphasSize | ( | ) | const |
Get the alpha values buffer size in bytes.
FGAPI unsigned colors | ( | ) | const |
Get the buffer identifier for color values per vertex.
FGAPI unsigned colorsSize | ( | ) | const |
Get the colors buffer size in bytes.
FGAPI unsigned radii | ( | ) | const |
Get the buffer identifier for per vertex marker sizes.
FGAPI unsigned radiiSize | ( | ) | const |
Get the marker sizes buffer size in bytes.
FGAPI void setColor | ( | const float | pRed, |
const float | pGreen, | ||
const float | pBlue, | ||
const float | pAlpha | ||
) |
Set the color of line graph(plot)
[in] | pRed | is Red component in range [0, 1] |
[in] | pGreen | is Green component in range [0, 1] |
[in] | pBlue | is Blue component in range [0, 1] |
[in] | pAlpha | is Blue component in range [0, 1] |
FGAPI void setColor | ( | const forge::Color | pColor | ) |
Set the color of line graph(plot)
[in] | pColor | takes values of forge::Color to define plot color |
FGAPI void setLegend | ( | const char * | pLegend | ) |
Set plot legend.
[in] | pLegend |
FGAPI void setMarkerSize | ( | const float | pMarkerSize | ) |
Set global marker size.
This size will be used for rendering markers if no per vertex marker sizes are provided. This value defaults to 10
[in] | pMarkerSize | is the target marker size for scatter plots or line plots with markers |
FGAPI unsigned vertices | ( | ) | const |
Get the buffer identifier for vertices.
FGAPI unsigned verticesSize | ( | ) | const |
Get the vertex buffer size in bytes.