All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
IAnchoredLabel.h
1 // Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2 
3 #pragma once
4 
5 
6 #include "Labels.h"
7 #include "Text.h"
8 #include "VectorMath.h"
9 #include "AxisAlignedBox2.h"
10 #include "Icons.h"
11 #include "LabelAnchorCategory.h"
12 
13 #include <string>
14 #include <vector>
15 
16 namespace Eegeo
17 {
18  namespace Labels
19  {
21  {
22  public:
23  typedef std::string IdType;
24 
25  virtual ~IAnchoredLabel() {;}
26 
27  virtual IdType GetId() const = 0;
28 
29  virtual const std::string& GetEntityName() const = 0;
30 
31  virtual const LabelAnchorCategory& GetLabelAnchorCategory() const = 0;
32 
33  virtual void GetShapedGlyphs(std::vector<Text::ShapedGlyph>& out_shapedGlyphs) const = 0;
34 
35  virtual const Icons::IconDefinition* GetIconDefinition() const = 0;
36 
37  virtual dv3 GetEcefAnchorPosition() const = 0;
38 
39  virtual v3 GetAnchorOffset() const = 0;
40 
41  virtual m44 CalcFeatureAlignedAnchorBasisEcef(float environmentFlatteningScale) const = 0;
42 
43  virtual Geometry::AxisAlignedBox2 GetLocalTextBounds() const = 0;
44 
45  virtual float GetConstraintRadiusEcef() const = 0;
46 
47  virtual bool CanCacheAnchorOffset() const = 0;
48 
49  virtual int GetSubPriority() const = 0;
50  };
51 
53  {
54  virtual void SetEcefAnchorPosition(const dv3& ecefAnchorPosition) = 0;
55 
56  virtual void SetTransform(const m44& transform) = 0;
57 
58  virtual void SetLabelText(const std::string& labelTextUtf8) = 0;
59 
60  virtual void SetIconKey(const std::string& iconKey) = 0;
61 
62  virtual void SetLocalAnchorOffset(const v3& localAnchorOffset) = 0;
63  };
64  }
65 }