diff options
author | Marius Kintel <marius@kintel.net> | 2013-02-12 04:33:31 (GMT) |
---|---|---|
committer | Marius Kintel <marius@kintel.net> | 2013-05-10 11:45:28 (GMT) |
commit | 130e10778e9d74ceb07dfc813b85d75a52a71e10 (patch) | |
tree | f11ad6722ff461864d83906b29bbabe148858693 /src/dxftess-cgal.cc | |
parent | b5079a189aa70cf36e9a4ded6d891df6ae78ac58 (diff) |
Initial code to support scaling of linear_extrude(). Part of Issue #273
Diffstat (limited to 'src/dxftess-cgal.cc')
-rw-r--r-- | src/dxftess-cgal.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dxftess-cgal.cc b/src/dxftess-cgal.cc index 0197473..fffa4f1 100644 --- a/src/dxftess-cgal.cc +++ b/src/dxftess-cgal.cc @@ -101,7 +101,7 @@ void mark_inner_outer(std::vector<struct triangle> &tri, Grid2d<point_info_t> &p } } -void dxf_tesselate(PolySet *ps, DxfData &dxf, double rot, bool up, bool /* do_triangle_splitting */, double h) +void dxf_tesselate(PolySet *ps, DxfData &dxf, double rot, double scale, bool up, bool /* do_triangle_splitting */, double h) { CDT cdt; @@ -124,8 +124,8 @@ void dxf_tesselate(PolySet *ps, DxfData &dxf, double rot, bool up, bool /* do_tr struct point_info_t *first_pi = NULL, *prev_pi = NULL; for (size_t j = 1; j < dxf.paths[i].indices.size(); j++) { - double x = dxf.points[dxf.paths[i].indices[j]][0]; - double y = dxf.points[dxf.paths[i].indices[j]][1]; + double x = scale * dxf.points[dxf.paths[i].indices[j]][0]; + double y = scale * dxf.points[dxf.paths[i].indices[j]][1]; if (point_info.has(x, y)) { // FIXME: How can the same path set contain the same point twice? |