Welcome to mirror list, hosted at ThFree Co, Russian Federation.

path_renderer.hpp « graphics - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a7eb6cad226e44ff437222e7561deded7ab06f4e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#pragma once

#include "area_renderer.hpp"
#include "../geometry/point2d.hpp"

namespace graphics
{
  struct Pen;

  class PathRenderer : public AreaRenderer
  {
  private:

    unsigned m_pathCount;
    unsigned m_pointsCount;
    bool m_drawPathes;

    void drawSolidPath(m2::PointD const * pts, size_t ptsCount, double offset, Pen const * pen, double depth);
    void drawStipplePath(m2::PointD const * pts, size_t ptsCount, double offset, Pen const * pen, double depth);
    void drawSymbolPath(m2::PointD const * pts, size_t ptsCount, double offset, Pen const * pen, double depth);

  public:

    typedef AreaRenderer base_t;

    struct Params : base_t::Params
    {
      bool m_drawPathes;
      Params();
    };

    PathRenderer(Params const & params);

    void drawPath(m2::PointD const * pts, size_t ptsCount, double offset, uint32_t resID, double depth);

    void beginFrame();
    void endFrame();

  };
}