esvg: Ewol SVG parser and renderer 0.7.4
Main Page
Related Pages
Namespaces
Classes
Files
Link-libs
lutin
ewol
etk
ejson
exml
esvg
egami
gale
ege
elog
ememory
enet
eproperty
esignal
zeus
audio-ess
audio
audio-drain
audio-orchestra
audio-river
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
framework
atria-soft
esvg
esvg
render
Element.hpp
Go to the documentation of this file.
1
6
#pragma once
7
8
#include <
etk/types.hpp
>
9
#include <
etk/math/Vector2D.hpp
>
10
11
namespace
esvg
{
12
namespace
render {
13
enum
path {
14
path_stop,
15
path_close,
16
path_moveTo,
17
path_lineTo,
18
path_lineToH,
19
path_lineToV,
20
path_curveTo,
21
path_smoothCurveTo,
22
path_bezierCurveTo,
23
path_bezierSmoothCurveTo,
24
path_elliptic
25
};
26
class
Element
{
27
public
:
28
Element
(
enum
path _type,
bool
_relative=
false
) :
29
m_cmd(_type),
30
m_relative(_relative) {
31
32
}
33
virtual
~
Element
() { }
34
private
:
35
enum
path m_cmd;
36
public
:
37
enum
path getType()
const
{
38
return
m_cmd;
39
}
40
protected
:
41
bool
m_relative;
42
public
:
43
bool
getRelative()
const
{
44
return
m_relative;
45
}
46
void
setRelative(
bool
_relative) {
47
m_relative = _relative;
48
}
49
protected
:
50
vec2
m_pos;
51
public
:
52
const
vec2
& getPos()
const
{
53
return
m_pos;
54
}
55
void
setPos(
const
vec2
& _val) {
56
m_pos = _val;
57
}
58
protected
:
59
vec2
m_pos1;
60
public
:
61
const
vec2
& getPos1()
const
{
62
return
m_pos1;
63
}
64
void
setPos1(
const
vec2
& _val) {
65
m_pos1 = _val;
66
}
67
protected
:
68
vec2
m_pos2;
69
public
:
70
const
vec2
& getPos2()
const
{
71
return
m_pos2;
72
}
73
void
setPos2(
const
vec2
& _val) {
74
m_pos2 = _val;
75
}
76
public
:
77
virtual
std::string display()
const
= 0;
78
};
79
}
83
std::ostream& operator <<(std::ostream& _os,
const
esvg::render::Element
& _obj);
87
std::ostream& operator <<(std::ostream& _os,
enum
esvg::render::path _obj);
88
}
89
90
#include <
esvg/render/ElementStop.hpp
>
91
#include <
esvg/render/ElementClose.hpp
>
92
#include <
esvg/render/ElementMoveTo.hpp
>
93
#include <
esvg/render/ElementLineTo.hpp
>
94
#include <
esvg/render/ElementLineToH.hpp
>
95
#include <
esvg/render/ElementLineToV.hpp
>
96
#include <
esvg/render/ElementCurveTo.hpp
>
97
#include <
esvg/render/ElementSmoothCurveTo.hpp
>
98
#include <
esvg/render/ElementBezierCurveTo.hpp
>
99
#include <
esvg/render/ElementBezierSmoothCurveTo.hpp
>
100
#include <
esvg/render/ElementElliptic.hpp
>
101
ElementClose.hpp
esvg
Main esvg namespace.
Definition:
Base.hpp:24
ElementBezierCurveTo.hpp
ElementBezierSmoothCurveTo.hpp
ElementStop.hpp
ElementLineToH.hpp
Vector2D.hpp
types.hpp
ElementSmoothCurveTo.hpp
ElementLineTo.hpp
esvg::render::Element
Definition:
Element.hpp:26
ElementCurveTo.hpp
ElementElliptic.hpp
etk::Vector2D< float >
ElementLineToV.hpp
ElementMoveTo.hpp
Generated on Mon Oct 24 2016 10:48:21 for esvg: Ewol SVG parser and renderer by
1.8.12