20#ifndef ANNOTATIONRENDERER_H
21#define ANNOTATIONRENDERER_H
60 void AddText(
string text,
int x,
int y,
int size,
float color[3],
int type = 0);
72#ifdef VAPOR3_0_0_ALPHA
74 void invalidateCache();
88 vector<billboard> _billboards;
89 vector<billboard> _timeAnnot;
90 vector<billboard> _axisAnnot;
91 vector<billboard> _miscAnnot;
101 void _drawAxes(std::vector<double> min, std::vector<double> max, std::vector<double> origin, std::vector<double> color,
double width);
102 void _drawTic(
double startPosn[],
double endPosn[],
double width, std::vector<double> color);
103 void _drawTimeAnnotation();
105 void _makeTransformMatrix(
const Transform *transform, glm::mat4 &transformMatrix)
const;
107 void _applyDataMgrCornerToDomain(std::vector<double> &domainExtents,
const glm::vec4 &dataMgrCorner,
const glm::mat4 &transformMatrix)
const;
109 void _getDataMgrCorner(
const int cornerNumber, glm::vec4 &dataMgrCorner,
const CoordType &minDataMgrExtents,
const CoordType &maxDataMgrExtents)
const;
111 void _applyDataMgrToDomainExtents(std::vector<double> &domainExtents,
const CoordType &dataMgrMinExts,
const CoordType &dataMgrMaxExts,
const Transform *transform)
const;
113 void _calculateDomainExtents(std::vector<double> &domainExtents)
const;
115 void drawDomainFrame(
const std::vector<double> corners)
const;
117 std::vector<double> getDomainExtents()
const;
119 string getCurrentDataMgrName()
const;
120 void scaleNormalizedCoordinatesToWorld(std::vector<double> &coords,
string dataMgrName);
127 void _configureMatrixForArrows(
MatrixManager *matrixManager);
129#ifdef VAPOR3_0_0_ALPHA
131 void drawRegionBounds(
size_t ts)
const;
137 void drawAxisTics(
AxisAnnotation *aa, std::vector<double> minTic, std::vector<double> maxTic);
140 void renderText(
double text,
double coords[],
AxisAnnotation *aa = NULL);
141 Transform *getTransform(
string dataMgr =
"");
142 void convertPointToLonLat(
double &xCoord,
double &yCoord);
144#ifdef VAPOR3_0_0_ALPHA
157 static void ConvertAxes(
bool toLatLon,
const vector<long> ticDirs,
const vector<double> fromMinTic,
const vector<double> fromMaxTic,
const vector<double> fromOrigin,
158 const vector<double> fromTicLength,
double toMinTic[3],
double toMaxTic[3],
double toOrigin[3],
double toTicLength[3]);
161 static void flatConvertFromLonLat(
double x[2],
double minLon,
double maxLon,
double minX,
double maxX);
Class that draws various geometry as specified by AnnotationParams.
void DrawAxisArrows()
Draw Axis arrows.
void InScenePaint(size_t ts)
Render the in-scene features.
void AddText(string text, int x, int y, int size, float color[3], int type=0)
void DrawText(vector< billboard > billboards)
void AddTextNormalizedCoords(string text, float x, float y, int size, float color[3], int type=0)
AnnotationRenderer(const ParamsMgr *pm, const DataStatus *dataStatus, string winName)
Constructor, must invoke Renderer constructor.
virtual ~AnnotationRenderer()
Destructor.
void ClearText(int type=-1)
void InitializeGL(GLManager *glManager)
Method to initialize GL rendering. Must be called from a GL context.
void OverlayPaint(size_t ts)
Render the overlay features.
class that indicates location and direction of view
A class for describing the currently loaded dataset.
Replaces the OpenGL matrix stack.
A singleton class for managing Params instances.
std::array< double, 3 > CoordType
Type for specifying floating point coordinates.
Contains references to context scope OpenGL data.