39#ifndef DISTI_INCLUDED_GLS_LINEAR_SCALE_H
40#define DISTI_INCLUDED_GLS_LINEAR_SCALE_H
52#if( defined( GLSGEN_EXPORT_GLSLINEARSCALE ) || defined( GLSGEN_IMPORT_GLSLINEARSCALE ) || defined( GLS_EXPORT_GENERATED ) || defined( GLS_IMPORT_GENERATED ) ) \
53 && defined( _MSC_VER )
54# if defined( GLSGEN_EXPORT_GLSLINEARSCALE ) || defined( GLS_EXPORT_GENERATED )
55# define GLSGEN_GLSLINEARSCALE_EXPORT __declspec( dllexport )
57# define GLSGEN_GLSLINEARSCALE_EXPORT __declspec( dllimport )
60# define GLSGEN_GLSLINEARSCALE_EXPORT
65#define LIB_BASE_NAME "gls_linear_scale"
74 GLS_LINEAR_SCALE_FIRST_VALUE = GLS_LAST_INITIALIZER + 1,
75 GLS_LINEAR_SCALE_RADII,
76 GLS_LINEAR_SCALE_DECONFLICT_TICKS,
77 GLS_LINEAR_SCALE_HALO_ENABLED,
78 GLS_LINEAR_SCALE_HALO_WIDTH,
79 GLS_LINEAR_SCALE_HALO_COLOR,
80 GLS_LINEAR_SCALE_TICK_ANCHOR,
81 GLS_LINEAR_SCALE_USE_SCALABLE_LINES,
89 GLS_TICK_ANCHOR_BOTTOM,
90 GLS_TICK_ANCHOR_CENTER
117 ,
color( 255, 255, 255, 255 )
135 float _startingOffset,
208#define GLS_LINEAR_SCALE_MAX 5
219 friend class GlsLinearScaleEditor;
226 DISTI_DEPRECATED(
"This identifier is forbidden by the C++ standard. Use BaseClass instead." )
334 _geometryRefresh =
true;
426 void DrawScale(
int i,
float haloLength,
float haloThickness );
Definition: disti_metadata.h:87
Definition: callback_caller_base.h:55
Definition: disti_metadata.h:750
void CopyCommonValues(const DistiAttribDict &dict)
Definition: disti_metadata.h:220
Definition: gls_linear_scale.h:473
std::ostream & WriteValue(std::ostream &outstr) DISTI_METHOD_OVERRIDE
bool OkToWrite() const DISTI_METHOD_OVERRIDE
GlsLinearScaleDataArray * _attribPtr
Observer of the underlying storage for the property.
Definition: gls_linear_scale.h:475
unsigned int _arraySize
Always GLS_LINEAR_SCALE_MAX.
Definition: gls_linear_scale.h:476
DistiAttributeConnectionGlsLinearScaleDataArray(CallbackMethodCallerBase *callback, const AttributeName &name, GlsLinearScaleDataArray *attribPtr, int arraySize)
Definition: gls_linear_scale.h:484
std::istream & ReadValue(std::istream &instr) DISTI_METHOD_OVERRIDE
std::string Type() const DISTI_METHOD_OVERRIDE
Definition: dynamic_array.h:79
The Polygon class. Implements Polygons.
Definition: glpolygon.h:55
Definition: gls_color.h:53
Definition: gls_display_list.h:51
void Invalidate()
Definition: gls_display_list.h:85
Definition: gls_glo_file.h:1241
Definition: gls_linear_scale.h:95
bool active
True if this scale is active.
Definition: gls_linear_scale.h:100
float length
Length of ticks in logical units.
Definition: gls_linear_scale.h:105
GlsLinearScaleData(const GlsLinearScaleData &src)
Definition: gls_linear_scale.h:154
bool operator==(const GlsLinearScaleData &right) const
DistiAttribDict _attribDict
The attribute dictionary for this class' members.
Definition: gls_linear_scale.h:97
float interval
Interval between ticks in logical units.
Definition: gls_linear_scale.h:104
float thickness
Thickness of ticks in logical units.
Definition: gls_linear_scale.h:106
GlsColor color
Color to draw ticks if line color is not being used.
Definition: gls_linear_scale.h:107
float startingOffset
Start offset in logical units.
Definition: gls_linear_scale.h:103
unsigned int ticks
Number of ticks on this scale.
Definition: gls_linear_scale.h:102
bool operator!=(const GlsLinearScaleData &right) const
Definition: gls_linear_scale.h:189
std::istream & ReadValue(std::istream &instr)
std::ostream & WriteValue(std::ostream &outstr)
bool useLineColor
True if this scale draws with line color.
Definition: gls_linear_scale.h:101
void InitMetaData()
Create DistiAttributes for this object's members.
GlsLinearScaleData & operator=(const GlsLinearScaleData &src)
Definition: gls_linear_scale.h:163
GlsLinearScaleData(bool _active, bool _useLineColor, unsigned int _ticks, float _startingOffset, float _interval, float _length, float _thickness, const GlsColor &_color)
Definition: gls_linear_scale.h:131
Definition: gls_linear_scale.h:218
float _currentLineWidth
Definition: gls_linear_scale.h:384
GlsColor _haloColor
Definition: gls_linear_scale.h:460
virtual void DrawGeometry()
void SetValue(int spec, va_list &args) DISTI_METHOD_OVERRIDE
void CurrentLineWidth(const float &newLineWidth)
GlsColor HaloColor()
Definition: gls_linear_scale.h:313
void CopyProperties(DisplayObject *src) DISTI_METHOD_OVERRIDE
void HaloEnabled(const bool &val)
void CurrentColor(const GlsColor &newColor)
GlsTickAnchor TickAnchor()
Definition: gls_linear_scale.h:323
bool _haloEnabled
Definition: gls_linear_scale.h:454
bool TickNeeded(int currentLevel, float currentOffset)
void SetAvailableAttributes(unsigned int value) DISTI_METHOD_OVERRIDE
void GetCppInterfaceDescriptionFree(InterfaceListType *array) DISTI_METHOD_OVERRIDE
void SetColor(const GlsColor &color) DISTI_METHOD_OVERRIDE
void UseScalableLines(const bool &val)
bool DeconflictTicks()
Definition: gls_linear_scale.h:288
float _haloWidth
Definition: gls_linear_scale.h:457
GlsDisplayList & DisplayList()
Definition: gls_linear_scale.h:358
bool HaloEnabled()
Definition: gls_linear_scale.h:293
bool _useScalableLines
Definition: gls_linear_scale.h:467
float HaloWidth()
Definition: gls_linear_scale.h:303
void PreDraw(const OpenGLMatrices &parentMatrices, Culler &culler) DISTI_METHOD_OVERRIDE
static DisplayObject * CreateInstance()
void Draw() DISTI_METHOD_OVERRIDE
void CopyGeometry(DisplayObject *srcArg) DISTI_METHOD_OVERRIDE
Vector _radii[2]
Definition: gls_linear_scale.h:442
GlsDisplayList _displayList
Definition: gls_linear_scale.h:395
void DrawScale(int i, float haloLength, float haloThickness)
void HaloColor(const GlsColor &val)
GlsColor _currentColor
Definition: gls_linear_scale.h:380
bool Hit(float x, float y, float z, float scale, const Vector &directionVector, Vector *collisionPoint) DISTI_METHOD_OVERRIDE
void Scale(float px, float py, float pz, Vertex *anchor, int handleBar) DISTI_METHOD_OVERRIDE
void TickAnchor(const GlsTickAnchor val)
bool _deconflictTicks
Definition: gls_linear_scale.h:451
void GetScale(int index, GlsLinearScaleData &data)
Vector _radiiNormalized[2]
Definition: gls_linear_scale.h:445
DisplayObject * CloneObject(bool generateNames=false) DISTI_METHOD_OVERRIDE
void HaloWidth(const float &val)
void InvalidateGeometry()
Definition: gls_linear_scale.h:351
bool _currentLineWidthSet
Definition: gls_linear_scale.h:392
bool UseScalableLines()
Definition: gls_linear_scale.h:343
bool _currentColorSet
Definition: gls_linear_scale.h:388
InterfaceListType * GetCppInterfaceDescription(InterfaceListType *addToThisList=NULL) DISTI_METHOD_OVERRIDE
GlsTickAnchor _tickAnchor
Definition: gls_linear_scale.h:463
void Rotate(const Vector &orig, float angle, const Vector &axis) DISTI_METHOD_OVERRIDE
void SetScale(int index, const GlsLinearScaleData &data)
GlsLinearScaleDataArray _scale
Definition: gls_linear_scale.h:448
Definition: gls_quad_storage.h:60
Class to contain current OpenGL view, projection and draw matrices.
Definition: util.h:540
The disti::GLPolygon class. Implements Polygons.
Macros and helper code to determine what subset of C++11/14/17 is available.
#define DISTI_SPECIAL_MEM_FUN_DELETE
Macro to wrap function deletion, removed on compilers that don't support it.
Definition: gls_cpp_lang_support.h:245
#define DISTI_DEPRECATED(msg)
Defines whether this compiler supports the C++14 deprecated attribute.
Definition: gls_cpp_lang_support.h:487
#define DISTI_METHOD_OVERRIDE
Macro to wrap the override keyword, removed on compilers that don't support it.
Definition: gls_cpp_lang_support.h:221
The disti::GlsDisplayList class.
#define GLS_LINEAR_SCALE_MAX
The maximum number of unique tick mark types.
Definition: gls_linear_scale.h:208
#define GLSGEN_GLSLINEARSCALE_EXPORT
Provides support for creating DLLs.
Definition: gls_linear_scale.h:60
The disti::GlsQuadListVC_3D and GlsQuadListVCT_2D classes.
Definition: bmpimage.h:46
GlsLinearScaleData GlsLinearScaleDataArray[5]
Typedef for one GlsLinearScale worth of scale data.
Definition: gls_linear_scale.h:210
GlsTickAnchor
Tick anchor behavior.
Definition: gls_linear_scale.h:87