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

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Treyer <treyer@arch.ethz.ch>2014-10-21 20:21:49 +0400
committerLukas Treyer <treyer@arch.ethz.ch>2014-10-21 20:21:49 +0400
commit570b7d94b3b2414e376d9eddd4f3a2df1e4dbb88 (patch)
tree03f8377ab8bac38c235567ccd975529d97bf7589 /io_import_dxf
parent68e4b7e6bf9ddd643bd8ac9b48b8b9aeaeae4b03 (diff)
FIX T42252: Arcs are scaled correctly now. The scale factor now also accepts comas, not only points (comas are being replaced by points internally).
Diffstat (limited to 'io_import_dxf')
-rw-r--r--io_import_dxf/__init__.py2
-rw-r--r--io_import_dxf/dxfimport/do.py13
2 files changed, 6 insertions, 9 deletions
diff --git a/io_import_dxf/__init__.py b/io_import_dxf/__init__.py
index fae5b173..d8385f89 100644
--- a/io_import_dxf/__init__.py
+++ b/io_import_dxf/__init__.py
@@ -496,7 +496,7 @@ class IMPORT_OT_dxf(bpy.types.Operator):
proj_scn = None
dxf_unit_scale = 1.0
if self.use_georeferencing:
- dxf_unit_scale = float(self.dxf_scale)
+ dxf_unit_scale = float(self.dxf_scale.replace(",", "."))
if PYPROJ:
if self.proj_dxf != 'NONE':
if self.proj_dxf == 'USER':
diff --git a/io_import_dxf/dxfimport/do.py b/io_import_dxf/dxfimport/do.py
index 82fea417..81124124 100644
--- a/io_import_dxf/dxfimport/do.py
+++ b/io_import_dxf/dxfimport/do.py
@@ -306,14 +306,7 @@ class Do:
e += 2 * pi
angle = e - s
- # curve == None means arc is called from bulge conversion
- # nothing should be projected at this stage, since the
- # lwpolyline (the only entity with bulges) will be projected
- # as a whole afterwars (small little error; took ages to debug)
- if curve is not None:
- vc = self.proj(en.center)
- else:
- vc = en.center
+ vc = Vector(en.center)
x_vec = Vector((1, 0, 0))
radius = en.radius
@@ -365,6 +358,10 @@ class Do:
if len(spline) % 3 != 1:
print("DXF-IMPORT: DO ARC: CHECK PLEASE: ", len(spline), spline)
+ # curve == None means arc is called from bulge conversion
+ # nothing should be projected at this stage, since the
+ # lwpolyline (the only entity with bulges) will be projected
+ # as a whole afterwards (small little error; took ages to debug)
if curve is not None:
self._cubic_bezier_open(spline, curve)
return spline