-
Notifications
You must be signed in to change notification settings - Fork 6
/
new_structure.uml
215 lines (197 loc) · 3.55 KB
/
new_structure.uml
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
@startuml
/' skinparam classBackgroundColor Wheat|CornflowerBlue '/
class SVGGeometry {
_node
_transform
_style
_context
_viewport
_name
__init__()
parse()
_parse_style()
_parse_transform()
_parse_viewport()
_push_transform(transform)
_pop_tranfsorm(transform)
_transform_coord(co)
_new_blender_curve_object(name)
_new_spline_to_blender_curve(curve_object_data, is_cyclic)
_new_blender_curve(name, is_cyclic)
_add_points_to_blender(coords, spline)
_get_material_with_color(color)
_calculate_style_in_context()
_push_style(style)
_pop_style()
_get_name_from_node()
_print_hierarchy(level=0)
}
class SVGGeometryContainer extends SVGGeometry{
_geometries
__init__(node, context)
parse()
create_blender_splines()
create_phovie_objects()
__repr__()
print_hierarchy(level=0)
}
class SVGGeometrySVG extends SVGGeometryContainer
{
viewport
_viewBox
_preserveAspectRatio
--
__init__()
parse()
create_blender_splines()
_view_to_transform()
_part_viewport()
_parse_viewBox()
_parse_preserveAspectRatio
_push_viewBox(viewBox)
_pop_viewBox(viewBox)
_calculate_viewBox_from_viewport()
--SVG Attributes--
id, class, style
viewBox
preserveAspectRatio
transform
x, y, width, height (viewport)
}
class SVGGeometryG extends SVGGeometryContainer
{
create_blender_splines()
--Attributes--
id, class, style
}
class SVGGeometryRECT extends SVGGeometry
{
_x
_y
_width
_height
_rx
_ry
__init__(node, context)
parse()
create_blender_splines()
create_phovie_objects()
static: _new_point(coordinate, handle_left=None, handle_right=None, in_type=None, out_type=None)
static: _new_path(is_closed=False)
}
class SVGGeometryELLIPSE extends SVGGeometry
{
_cx
_cy
_rx
_ry
_is_circle
__init__(node, context)
parse()
create_blender_splines()
}
class SVGGeometryCIRCLE extends SVGGeometryELLIPSE
class SVGGeometryLINE extends SVGGeometry
{
_x1
_y1
_x2
_y2
__init__(node, context)
parse()
create_blender_splines()
}
class SVGGeometryPOLYLINE
{
_points
_is_closed
__init__(node, context)
parse()
create_blender_splines()
}
SVGGeometry <|-- SVGGeometryPOLYLINE
class SVGGeometryPOLYGON
{
__init__(node, context)
}
SVGGeometryPOLYLINE <|-- SVGGeometryPOLYGON
class SVGGeometryPATH
{
_splines
__init__(node, context)
parse()
create_blender_splines()
}
SVGGeometry <|-- SVGGeometryPATH
class SVGPATHParser
{
_data
_index
_current_spline
_splines
_commands
_spline_start
__init__(d)
parse()
get_data()
_get_next_coord_pair(relative, previous_point)
_get_next_coord(relative, previous_point)
_get_last_point()
_path_move_to(command)
_path_line_to(command)
_path_curve_to(command)
_path_elliptical_arc_to(command)
_calculate_arc( rx, ry, angle, fA, fS, x1, y1, x2, y2)
_correct_radii(rx, ry, xp, yp)
_flip_handle(handle)
_path_close(command)
}
class SVGPATHDataSupplier
{
_data
_index
_len
__init__(d)
eof()
check_next()
next()
next_coord()
}
class SVGGeometrySYMBOL extends SVGGeometrySVG
{
--SVG Attributes--
id, class, style
preserveAspectRatio
viewBox
refX: left | center | right
refY: top | center | bottom
x, y, width, height (viewport)
}
class SVGGeometryDEFS extends SVGGeometryContainer
{
--SVG Attributes--
id, class, style
}
class SVGGeometryUSE extends SVGGeometry
{
viewport
_href
--
parse()
create_blender_splines()
_parse_viewport()
--SVG Attributes--
id, class, style
x, y, width, height
height and width only
matters if the referenced
element defines viewport (svg, symbol).
If so, anything else than auto will overide
the corresponding geometric property of that
element.
}
class SVGLoader extends SVGGeometryContainer
{
__init__(blender_context, svg_filepath, origin="TL", depth="0")
}
@enduml