40 #ifndef _GLS_ANGULAR_SCALE_H
41 #define _GLS_ANGULAR_SCALE_H
47 #include "gls_quad_storage.h"
53 #if (defined(GLSGEN_EXPORT_GLSANGULARSCALE) || \
54 defined(GLSGEN_IMPORT_GLSANGULARSCALE) || \
55 defined(GLS_EXPORT_GENERATED) || \
56 defined(GLS_IMPORT_GENERATED)) \
58 # if defined(GLSGEN_EXPORT_GLSANGULARSCALE) || defined(GLS_EXPORT_GENERATED)
59 # define GLSGEN_GLSANGULARSCALE_EXPORT __declspec(dllexport)
61 # define GLSGEN_GLSANGULARSCALE_EXPORT __declspec(dllimport)
64 # define GLSGEN_GLSANGULARSCALE_EXPORT
68 #define LIB_BASE_NAME "gls_angular_scale"
77 class GlsGloFileAttribute;
81 GLS_ANGULAR_SCALE_FIRST_VALUE = GLS_LAST_INITIALIZER+1,
82 GLS_ANGULAR_SCALE_RADII,
83 GLS_ANGULAR_SCALE_DECONFLICT_TICKS,
84 GLS_ANGULAR_SCALE_HALO_ENABLED,
85 GLS_ANGULAR_SCALE_HALO_WIDTH,
86 GLS_ANGULAR_SCALE_HALO_COLOR,
87 GLS_ANGULAR_SCALE_USE_SCALABLE_LINES,
88 GLS_ANGULAR_SCALE_RADIUS,
89 GLS_ANGULAR_SCALE_DATA
115 color(255,255,255,255)
130 useLineColor(_useLineColor),
132 startAngle(_startAngle),
135 thickness(_thickness),
141 GlsAngularScaleData(
const GlsAngularScaleData& src)
146 ~GlsAngularScaleData(
void)
150 bool GLSGEN_GLSANGULARSCALE_EXPORT operator==(
const GlsAngularScaleData& right )
const;
152 bool GLSGEN_GLSANGULARSCALE_EXPORT operator!=(
const GlsAngularScaleData& right )
const
154 return !( this->operator==( right ) );
157 void GLSGEN_GLSANGULARSCALE_EXPORT InitMetaData(
void);
160 virtual GLSGEN_GLSANGULARSCALE_EXPORT std::ostream & WriteValue(std::ostream &outstr);
163 virtual GLSGEN_GLSANGULARSCALE_EXPORT std::istream & ReadValue(std::istream &instr);
166 #define GLS_ANGULAR_SCALE_MAX 5
168 typedef GlsAngularScaleData GlsAngularScaleDataArray[GLS_ANGULAR_SCALE_MAX];
173 friend class GlsAngularScaleEditor;
185 GLSGEN_GLSANGULARSCALE_EXPORT
GlsAngularScale(
bool generateInstance=
false);
192 GLSGEN_GLSANGULARSCALE_EXPORT GlsAngularScale(
const GlsAngularScale& that,
const bool generateNames );
197 static GLSGEN_GLSANGULARSCALE_EXPORT
DisplayObject* CreateInstance();
212 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void Draw(
void);
214 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void Scale(
float px,
float py,
float pz,
Vertex *anchor,
int handleBar);
215 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void Rotate(
const Vector &orig,
float angle,
const Vector &axis);
216 virtual GLSGEN_GLSANGULARSCALE_EXPORT
bool Hit(
float x,
float y,
float z,
float scale,
const Vector& directionVector,
Vector *collisionPoint);
219 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void GetExtents(
float &minx,
float &miny,
float &minz,
float &maxx,
float &maxy,
float &maxz);
227 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void AntiAlias(
bool alias);
232 virtual void SetValue(
int spec,va_list &args);
269 GLSGEN_GLSANGULARSCALE_EXPORT
void HaloEnabled(
const bool &val);
279 GLSGEN_GLSANGULARSCALE_EXPORT
void HaloWidth(
const float &val);
306 GLSGEN_GLSANGULARSCALE_EXPORT
float Radius(
void)
314 GLSGEN_GLSANGULARSCALE_EXPORT
void Radius(
const float &val);
318 GLSGEN_GLSANGULARSCALE_EXPORT
void InvalidateGeometry(
void) { _geometryRefresh =
true; }
340 GlsQuadListVC_3D _quads;
379 bool TickNeeded(
int currentLevel,
float currentAngle);
390 void DrawScale(
int i,
float haloLength,
float haloThickness);
397 virtual GLSGEN_GLSANGULARSCALE_EXPORT
void SetFromGloData(GlsGloFileAttribute &data);
439 GlsAngularScaleDataArray* _attribPtr;
440 unsigned int _arraySize;
446 _attribPtr(attribPtr),
447 _arraySize(arraySize)
453 virtual std::ostream &
WriteValue(std::ostream &outstr);
454 virtual std::istream &
ReadValue(std::istream &instr);
virtual void GetExtents(float &minx, float &miny, float &minz, float &maxx, float &maxy, float &maxz)
virtual void PreDraw(const OpenGLMatrices &parentMatrices, Culler &culler)
void SetScale(int index, const GlsAngularScaleData &data)
float thickness
Definition: gls_angular_scale.h:104
Definition: gls_angular_scale.h:92
virtual std::ostream & WriteValue(std::ostream &outstr)
float HaloWidth(void)
Definition: gls_angular_scale.h:274
void Invalidate(void)
Definition: gls_display_list.h:83
void DrawScale(int i, float haloLength, float haloThickness)
glsColor HaloColor(void)
Definition: gls_angular_scale.h:284
Definition: dynamic_array.h:63
bool _haloEnabled
Definition: gls_angular_scale.h:421
Class to contain current OpenGL view, projection and draw matrices.
Definition: util.h:289
bool _needsRecalculate
Definition: gls_angular_scale.h:330
virtual void UpdateBoundingVolume(void)
virtual void SetColor(const glsColor &color)
void GetScale(int index, GlsAngularScaleData &data)
virtual void SetAvailableAttributes(unsigned int value)
The Polygon class. Implements Polygons.
Definition: glpolygon.h:56
virtual void SetValue(int spec, va_list &args)
void CurrentColor(const glsColor &newColor)
bool _useScalableLines
Definition: gls_angular_scale.h:431
GlsDisplayList _displayList
Definition: gls_angular_scale.h:370
glsColor _haloColor
Definition: gls_angular_scale.h:427
virtual void CopyGeometry(DisplayObject *srcArg)
The disti::GLPolygon class. Implements Polygons.
bool HaloEnabled(void)
Definition: gls_angular_scale.h:264
void CalculateRadiiUnit(void)
virtual void GetCppInterfaceDescriptionFree(InterfaceListType *array)
bool UseScalableLines(void)
Definition: gls_angular_scale.h:295
float length
Definition: gls_angular_scale.h:103
GlsDisplayList & DisplayList(void)
Definition: gls_angular_scale.h:324
float startAngle
Definition: gls_angular_scale.h:101
Definition: gls_display_list.h:51
virtual DisplayObject * CloneObject(bool generateNames=false)
virtual bool Hit(float x, float y, float z, float scale, const Vector &directionVector, Vector *collisionPoint)
float _haloWidth
Definition: gls_angular_scale.h:424
bool _currentLineWidthSet
Definition: gls_angular_scale.h:367
virtual ~GlsAngularScale()
Definition: disti_metadata.h:179
void InvalidateGeometry(void)
Definition: gls_angular_scale.h:321
Definition: disti_metadata.h:661
Definition: callback_caller_base.h:56
bool TickNeeded(int currentLevel, float currentAngle)
bool _currentColorSet
Definition: gls_angular_scale.h:363
glsColor _currentColor
Definition: gls_angular_scale.h:355
virtual Vertex * Vertices()
Definition: gls_color.h:54
Vector _radii[2]
Definition: gls_angular_scale.h:406
virtual void DrawGeometry(void)
bool useLineColor
Definition: gls_angular_scale.h:99
GlsAngularScaleDataArray _scale
Definition: gls_angular_scale.h:415
void CurrentLineWidth(const float &newLineWidth)
float Radius(void)
Definition: gls_angular_scale.h:306
virtual bool OkToWrite() const
virtual std::istream & ReadValue(std::istream &instr)
virtual void Rotate(const Vector &orig, float angle, const Vector &axis)
virtual void CopyProperties(DisplayObject *src)
virtual void GetTransformedExtents(Vector &min, Vector &max, const GlsMatrixType &matrix, bool resetMinMax)
virtual bool AntiAlias(void)
DisplayObject * handle(DisplayEvent *ev)
bool DeconflictTicks(void)
Definition: gls_angular_scale.h:258
unsigned int ticks
Definition: gls_angular_scale.h:100
bool active
Definition: gls_angular_scale.h:98
virtual void Scale(float px, float py, float pz, Vertex *anchor, int handleBar)
virtual InterfaceListType * GetCppInterfaceDescription(InterfaceListType *addToThisList=NULL)
float interval
Definition: gls_angular_scale.h:102
Macros and helper code to determine what subset of C++11/14/17 is available.
Definition: disti_metadata.h:83
Vector _radiiUnit[2]
Definition: gls_angular_scale.h:409
Definition: gls_angular_scale.h:436
bool _deconflictTicks
Definition: gls_angular_scale.h:418
void RecomputeVertices(void)
Definition: bmpimage.h:46
The disti::GlsDisplayList class.
Definition: gls_angular_scale.h:171
glsColor color
Definition: gls_angular_scale.h:105
float _magnitude[2]
Definition: gls_angular_scale.h:412
float _currentLineWidth
Definition: gls_angular_scale.h:359
void MagnitudeChanged(void)