All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
BatchedTextAppearanceBuilder.h
1 // Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2 
3 #pragma once
4 
5 #include "Types.h"
6 #include "Text.h"
7 #include "VectorMath.h"
8 #include "BatchedTextAppearance.h"
9 #include "Graphics.h"
10 
11 namespace Eegeo
12 {
13  namespace Text
14  {
16  {
17  public:
19 
20  BatchedTextAppearanceBuilder& SetSize(float size);
21 
22  BatchedTextAppearanceBuilder& SetGlyphColor(const v4& glyphColor);
23 
24  BatchedTextAppearanceBuilder& SetOutlineColor(const v4& outlineColor);
25 
26  BatchedTextAppearanceBuilder& SetHaloColor(const v4& haloColor);
27 
28  BatchedTextAppearanceBuilder& SetHaloWidth(float haloWidth);
29 
30  BatchedTextAppearanceBuilder& SetHaloHardness(float haloHardness);
31 
32  BatchedTextAppearanceBuilder& SetDepthTest(bool depthTest);
33 
34  BatchedTextAppearanceBuilder& SetStencilTest(bool stencilTest);
35 
36  BatchedTextAppearanceBuilder& SetStencilFunc(GLenum stencilFunc, int stencilRef, u32 stencilMask);
37 
38  BatchedTextAppearanceBuilder& SetStencilMaskedStyle(bool enable, GLenum stencilFunc, const v4& glyphColor, const v4& haloColor);
39 
40  BatchedTextAppearanceBuilder& SetFromTextAppearance(const BatchedTextAppearance& textApperance);
41 
43 
44  BatchedTextAppearance Build();
45 
46  private:
47  v4 m_glyphColor;
48  v4 m_outlineColor;
49  v4 m_haloColor;
50  v4 m_stencilMaskedGlyphColor;
51  v4 m_stencilMaskedHaloColor;
52  float m_size;
53  float m_haloWidth;
54  float m_haloHardness;
55  int m_stencilRef;
56  u32 m_stencilMask;
57  GLenum m_stencilFunc;
58  GLenum m_stencilMaskedStyleStencilFunc;
59  bool m_depthTest;
60  bool m_stencilTest;
61  bool m_stencilMaskedStyleEnabled;
62  };
63  }
64 }