MardyGit
-
Posts
5 -
Joined
-
Last visited
Posts posted by MardyGit
-
-
I would assume Designer & Photo share the same code base, so would do similar things. I'm guessing the Affinity coders did what I have had to do and put a default coordinate set in when any of the X or Y values appear out of bounds (0.0 to 1.0). The SVG specification doesn't state any bounds for the X & Y coordinate values, only the defaults. My concern is my code may get a valid linear gradient where the X & Y values are not in the range 0.0 to 1.0.
Guess I'll have to wait for Serif to pick this up.
Thanks for your help.
-
-
I've uploaded a version of the Affinity file, an SVG export and a screen-grab of our export settings.
It looks a little strange as it contains all of the animations 'frames'. Each group with a 'AA' prefix is a 'frame'. Our parser extracts the 'frames' in the exported SVGs and saves them to our proprietary binary vector format.
As we work only on MacOs, we can't verify this on Windows. MacOs preview, Safari and Edge show the incorrect linear gradient output. Affinity Design seems to fix this on re-import, but will re-export incorrectly. Oddly, I exported a single group and it worked fine, I didn't test every group.
This problem is with the linear gradient of the parrots wing.
-
We are exporting groups as SVGs from a large document to parse for animations. In one document a particular element is made of an inner group 10 paths. One of these paths has a simple 3 stop linear gradient. The element position is translated differently in each animation. The export is mangling the gradient coordinates. They should all be x1="0" y1="0" x2="1" y2="0", but some are getting values like x1="0" y1="0" x2="1" y2="-0.0293122", x1="0" y1="0" x2="1" y2="-2.48946" etc. For the moment I'm correcting this in our parser, but I shouldn't really have to do this.




Broken coordinate values on exporting linear gradient to svg
in Pre-V2 Archive of Affinity on Desktop Questions (macOS and Windows)
Posted
Sorry about the late reply, a birthday got in the way.
Good catch finding the cause of the bug.
I write software for living so have every sympathy with the developers of a complex code-base like Serif's. Of course I never create bugs myself, only unexpected features.
Hopefully someone will add this bug to the product backlog </hint>.