Age | Commit message (Collapse) | Author |
|
|
|
Differential Revision: https://developer.blender.org/D4319
|
|
The file saved as Inkscape SVG moved to the top, regular SVG stays in place. Blender checks if SVG have an special attribute `inkscape:version`, and if it has one, it move all SVG to the top. The idea is to match bottom right corner with world origin, instead top right corner:
But why height is not equal the real height of the SVG? Well, because it's not a height of SVG itself, it is size of SVG on printing or displaying in web-page or in previewer. The real height of SVG in SVG-units is located in viewbox attribute:
https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/viewBox
So I suggest to move SVG content to real height of SVG located in viewbox attribute:
Reviewers: sergey, antoniov
Reviewed By: antoniov
Subscribers: meta-androcto, antoniov, jms, sergey
Tags: #add-ons
Differential Revision: https://developer.blender.org/D5727
|
|
rBbc5b0f7a091c changed the default fill mode for curves.
Instead of being "fill" it is now "none".
The creates a problem because the svg importer seems to rely on curves being filled by default.
This diff should fix it.
(Note that this is my first patch)
Reviewers: sergey, mont29
Reviewed By: mont29
Subscribers: mont29
Differential Revision: https://developer.blender.org/D4582
|
|
Reviewers: sergey
Differential Revision: https://developer.blender.org/D4377
|
|
Some SVG exporters outputs small values in an exponential
notation. There is no big reason to reject those files.
This change makes it so any notation of the value is accepted.
Only do it in the path point parsing, since other areas are
already dealing with this correct.
Also covered the array parsing covered with a unit test which
can be run as a stand-alone application.
The parsing code is from Jacques Lucke, thanks!
Differential Revision: https://developer.blender.org/D4234
|
|
|
|
|
|
Fixes T55601: SVG import wrong shape
|
|
|
|
|
|
|
|
|
|
|
|
Patch provided by @cyp
|
|
|
|
|
|
|
|
Differential Revision: https://developer.blender.org/D3746
|
|
D3624 by @oirish
|
|
|
|
Was caused by fix for T45460. Now both reports should be fixed properly.
|
|
after the original objects
|
|
|
|
|
|
This is quite weak solution and not happy with it, but should cover
most of the use-cases.
|
|
|
|
io_curve_svg.import_svg.SVGParseFloat() may parse a float containing scientific
notation without an exponent sign. For example, 1e3 is a legal float value
according to the <number> syntax:
https://www.w3.org/TR/SVG11/types.html#DataTypeNumber
Example SVG file:
https://upload.wikimedia.org/wikipedia/commons/2/2f/Google_2015_logo.svg
Patch by Zac Mullett (aka zmullett), thanks!
Reviewers: sergey
Projects: #addons
Differential Revision: https://developer.blender.org/D1755
|
|
Push SVG tag rectangle before calculating the matrix.
This way scale will use proper SVG width and height.
|
|
Filled paths implies having final 'z' command to close the path.
|
|
|
|
Made some tweaks to transformation matrix of <svg> node to make
it so origin from Inkscape matches Blender origin.
Currently only affects files from Inkscape, for others it's not
so much clear what origin should be.
Based on the patch from aldero (juanC), thanks!
|
|
|
|
|
|
Apparently internally SVG importer was using 90 points per blender unit,
not per inch. This made files importing with unexpectable dimensions
which could be really harmful if you're importing blueprints as references.
Now SVG importer is using 90 points per inch, which makes imported files
has correct dimensions in both Metric and Imperal unit systems.
However, there's one possible downside -- imported files would look
smaller in blender units system.
|
|
|
|
|
|
Additional changes:
- Fixed wrong pop of rectangle area (function wasn't called)
- Removed unused code
|
|
|
|
|
|
|
|
|
|
- remove/comment unused variables
- remove unused imports
- fixed some bugs using incorrect variables
|
|
Update current point position when closing path is needed.
|
|
errors in code will still raise exceptions.
|
|
eg: XFCE file - /usr/share/xfce4/xkb/flags/tr.svg
|
|
Transformation for non-container objects was applied twice when they were USEd.
Get rid of confusing checks for special cases in USE.createGeom and use special
flag (instancing) which tells geometry is it "normal" geometry creation or
geometry creation initiated by USE node (SYMBOL would be handled differently
int this two cases)
Quick tests showed none regressions.
|
|
Suppose zero frictional part for case there's space or comma after
dot in float value. Inkscape sometimes uses such weird format.
|
|
- transform() only requires a single argument.
- support 'INVALID' as a unit suffix is present in some files created by docbook.
|
|
file from report [#26555] was raising an error becaues of this.
us.svg line 23
<use xlink:href="#star" x=" 0.126"/>
|