diff options
author | Ansis Brammanis <brammanis@gmail.com> | 2015-04-02 12:16:42 -0700 |
---|---|---|
committer | Ansis Brammanis <brammanis@gmail.com> | 2015-04-02 12:16:42 -0700 |
commit | 7b02800ad908347133494f9f1334d2384d5ead48 (patch) | |
tree | 328705da682cd8a0c0582025a4ec9099478dd22b /src/mbgl/text/quads.hpp | |
parent | 07b85043c8eb1feca4cea75e0460c35ba1325136 (diff) | |
download | qtlocation-mapboxgl-7b02800ad908347133494f9f1334d2384d5ead48.tar.gz |
remove old symbol collision types
Diffstat (limited to 'src/mbgl/text/quads.hpp')
-rw-r--r-- | src/mbgl/text/quads.hpp | 32 |
1 files changed, 28 insertions, 4 deletions
diff --git a/src/mbgl/text/quads.hpp b/src/mbgl/text/quads.hpp index 19acd72f46..b47cc718b6 100644 --- a/src/mbgl/text/quads.hpp +++ b/src/mbgl/text/quads.hpp @@ -1,22 +1,46 @@ #ifndef MBGL_TEXT_QUADS #define MBGL_TEXT_QUADS -#include <mbgl/text/types.hpp> #include <mbgl/text/glyph.hpp> - #include <mbgl/util/vec.hpp> +#include <vector> + namespace mbgl { + struct SymbolQuad { + explicit SymbolQuad(const vec2<float> &tl_, const vec2<float> &tr_, + const vec2<float> &bl_, const vec2<float> &br_, + const Rect<uint16_t> &tex_, float angle_, const vec2<float> &anchor_, + float minScale_, float maxScale_) + : tl(tl_), + tr(tr_), + bl(bl_), + br(br_), + tex(tex_), + angle(angle_), + anchor(anchor_), + minScale(minScale_), + maxScale(maxScale_) {} + + vec2<float> tl, tr, bl, br; + Rect<uint16_t> tex; + float angle; + vec2<float> anchor; + float minScale, maxScale; + }; + + typedef std::vector<SymbolQuad> SymbolQuads; + struct Anchor; class StyleLayoutSymbol; class PositionedIcon; - PlacedGlyphs getIconQuads(Anchor &anchor, const PositionedIcon &shapedIcon, + SymbolQuads getIconQuads(Anchor &anchor, const PositionedIcon &shapedIcon, const std::vector<Coordinate> &line, const StyleLayoutSymbol &layout, const bool alongLine); - PlacedGlyphs getGlyphQuads(Anchor &anchor, const Shaping &shapedText, + SymbolQuads getGlyphQuads(Anchor &anchor, const Shaping &shapedText, const float boxScale, const std::vector<Coordinate> &line, const StyleLayoutSymbol &layout, const bool alongLine, const GlyphPositions &face); } |