[Bf-extensions-cvs] [2fb7194] master: Fix T45460: SVG importer scale issues

Sergey Sharybin noreply at git.blender.org
Fri Jan 8 10:28:32 CET 2016


Commit: 2fb7194dba7a60c82642032c780a0652fdc56b88
Author: Sergey Sharybin
Date:   Fri Jan 8 14:26:25 2016 +0500
Branches: master
https://developer.blender.org/rBA2fb7194dba7a60c82642032c780a0652fdc56b88

Fix T45460: SVG importer scale issues

Push SVG tag rectangle before calculating the matrix.
This way scale will use proper SVG width and height.

===================================================================

M	io_curve_svg/import_svg.py

===================================================================

diff --git a/io_curve_svg/import_svg.py b/io_curve_svg/import_svg.py
index 611498a..333b823 100644
--- a/io_curve_svg/import_svg.py
+++ b/io_curve_svg/import_svg.py
@@ -1761,6 +1761,7 @@ class SVGGeometrySVG(SVGGeometryContainer):
         """
 
         rect = SVGRectFromNode(self._node, self._context)
+        self._pushRect(rect)
 
         matrix = self.getNodeMatrix()
 
@@ -1772,7 +1773,6 @@ class SVGGeometrySVG(SVGGeometryContainer):
             matrix = matrix * Matrix.Translation([0.0, -document_height , 0.0])
 
         self._pushMatrix(matrix)
-        self._pushRect(rect)
 
         super()._doCreateGeom(False)



More information about the Bf-extensions-cvs mailing list