Renderer for 2D axes in screen coordinates. The side to the right of the line from start to end position of the axis is defined as the "outside". As an example, consider the x axis at the bottom of a 2D plot, the outside is below the axis while the inside lies within the plot area. Mirroring the axis exchanges "outside" and "inside", that is labels and ticks will appear on the opposing side of the axis.
More...
#include <axisrenderer.h>
Renderer for 2D axes in screen coordinates. The side to the right of the line from start to end position of the axis is defined as the "outside". As an example, consider the x axis at the bottom of a 2D plot, the outside is below the axis while the inside lies within the plot area. Mirroring the axis exchanges "outside" and "inside", that is labels and ticks will appear on the opposing side of the axis.
◆ boundingRect()
std::pair< vec2, vec2 > inviwo::plot::AxisRenderer::boundingRect |
( |
const ivec2 & | startPos, |
|
|
const ivec2 & | endPos ) |
Returns the bounding rect (lower left, upper right) of the axis in pixels.
◆ render()
void inviwo::plot::AxisRenderer::render |
( |
const size2_t & | outputDims, |
|
|
const ivec2 & | startPos, |
|
|
const ivec2 & | endPos, |
|
|
bool | antialiasing = true ) |
Render the axis into the current framebuffer from pixel position startPos
to endPos
- Parameters
-
outputDims | Dimensions of the currently bound output framebuffer |
startPos | Start point of the axis in 2D screen coordinates [0, outputDims) |
endPos | End point of the axis in 2D screen coordinates [0, outputDims) |
antialiasing | If true, lines will be rendered using an exponential alpha fall-off at the edges and alpha blending |
The documentation for this class was generated from the following file: