wntrblm / Gingerbread

Web-based tool for creating artistic PCBs
Other
86 stars 5 forks source link

Guide to generate svg from Inkscape #5

Open PrithviRajNarendra opened 8 months ago

PrithviRajNarendra commented 8 months ago

First of all, thanks for this great tool! 👏

Inkscape is a good tool to generate svg art work which is also open source. Adding a guide to generate svgs from Inkscape similar to what's done for Affinity would be helpful.

wraybowling commented 3 months ago

Devoted Inkscape user here. I'm actively trying to understand what's different about my file from the examples.

Edit: 5 minutes later... OK yeah it's an issue with the fact that Inkscape uses namespaced layer labels instead of changing the group ID and Gingerbread relies on the id attribute. The quick hack is to open the XML editor window, and manually change the IDs to the mandatory ones.

Screenshot 2024-03-22 at 12 51 49 AM

wrickert commented 2 months ago

Yeah, seems like inkscape is not useable for this tool. Thats a shame. To add on to what wraybrwling has contributed: Go into the XML editor (Ctrl+Shift+X) and edit the ID to have the required labels (E.G 'Edge.Cuts', 'F.Cu', etc) This allows things to show up correctly in Gingerbread but Exporting it causes extremely low polygon images to appear in KiCAD. A 50mm image leaves Inkscape and a 0.75mm images appears (kinda) in KiCAD. I have to assume it has to do with DPI mismatch between what Inkscape outputs and what Gingerbread expects. I cant find any way to change this in inkscape, even exporting as a plain svg with the DPI setting at 2540 makes no change.

Any advice or tips would be very appreciated. Gingerbread seems very slick and I would dearly love to incorporate it to my workflow.

theacodes commented 2 months ago

I'm happy to accommodate Inkscape designs, but I don't have the time, energy, or desire to fight with Inkscape to figure out its quirks. I don't personally use Inkscape and have very limited, frustrating experience with it. If someone else felt like figuring out what's different between what Inkscape exports and what Gingerbread expects, I'd be happy to made changes to Gingerbread to support it.

bradanlane commented 2 months ago

Given that the Svg2Shenzhen plugin for InkScape is not officially "discontinued" and it even links to Gingerbread, I guess it's time for the InkScape+Svg2Shenzhen user base to pool our resources.

I have had the inverse experience as theacodes in that my use of Infinity Designer exposed too many bugs (with layers and transformations) to be useable for my recent designs.

Time permitting, I will fork Gingerbread and start looking at the issues starting with layer IDs and then SVG resolution settings.