diff options
author | falkTX <falktx@gmail.com> | 2015-04-27 22:57:47 +0200 |
---|---|---|
committer | falkTX <falktx@gmail.com> | 2015-04-27 22:57:47 +0200 |
commit | c5a6d6f7dc5119851cbc14dbfaa4d248985685d2 (patch) | |
tree | 55520b2170dd2be6b40039527c7812fa3e86ace7 /dgl/NanoVG.hpp | |
parent | 361f31b8f4bf063eda3bff95f1d912e3f298c7bf (diff) |
Finish updating, code builds again
Diffstat (limited to 'dgl/NanoVG.hpp')
-rw-r--r-- | dgl/NanoVG.hpp | 37 |
1 files changed, 28 insertions, 9 deletions
diff --git a/dgl/NanoVG.hpp b/dgl/NanoVG.hpp index 495aba1a..b0eaf0bf 100644 --- a/dgl/NanoVG.hpp +++ b/dgl/NanoVG.hpp @@ -168,6 +168,33 @@ private: class NanoVG { public: + enum CreateFlags { + /** + Flag indicating if geometry based anti-aliasing is used (may not be needed when using MSAA). + */ + CREATE_ANTIALIAS = 1 << 0, + + /** + Flag indicating if strokes should be drawn using stencil buffer. The rendering will be a little + slower, but path overlaps (i.e. self-intersecting or sharp turns) will be drawn just once. + */ + CREATE_STENCIL_STROKES = 1 << 1, + + /** + Flag indicating that additional debug checks are done. + */ + CREATE_DEBUG = 1 << 2, + }; + + enum ImageFlags { + IMAGE_GENERATE_MIPMAPS = 1 << 0, // Generate mipmaps during creation of the image. + IMAGE_REPEAT_X = 1 << 1, // Repeat image in X direction. + IMAGE_REPEAT_Y = 1 << 2, // Repeat image in Y direction. + IMAGE_FLIP_Y = 1 << 3, // Flips (inverses) image in Y direction when rendered. + IMAGE_PREMULTIPLIED = 1 << 4, // Image data has premultiplied alpha. + IMAGE_NODELETE = 1 << 16,// Do not delete GL texture handle. + }; + enum Align { // Horizontal align ALIGN_LEFT = 1 << 0, // Align horizontally to left (default). @@ -180,14 +207,6 @@ public: ALIGN_BASELINE = 1 << 6 // Align vertically to baseline (default). }; - enum ImageFlags { - IMAGE_GENERATE_MIPMAPS = 1 << 0, // Generate mipmaps during creation of the image. - IMAGE_REPEAT_X = 1 << 1, // Repeat image in X direction. - IMAGE_REPEAT_Y = 1 << 2, // Repeat image in Y direction. - IMAGE_FLIP_Y = 1 << 3, // Flips (inverses) image in Y direction when rendered. - IMAGE_PREMULTIPLIED = 1 << 4, // Image data has premultiplied alpha. - }; - enum LineCap { BUTT, ROUND, @@ -243,7 +262,7 @@ public: /** Constructor. */ - NanoVG(int textAtlasWidth = 512, int textAtlasHeight = 512); + NanoVG(int flags = CREATE_ANTIALIAS); /** Destructor. |