Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question about SVG branch... #77

Open
seandoyle opened this issue Jun 4, 2016 · 1 comment
Open

Question about SVG branch... #77

seandoyle opened this issue Jun 4, 2016 · 1 comment
Labels
deprioritized 👇 Not a current StoreBound priority, community progress only drawing 🖌️ User interface for drawing or creating art enhancement 🚀 New/enhanced functionality or out of scope improvements user experience 👨‍🎨 Anything involving user interface/buttons/experience

Comments

@seandoyle
Copy link

Hi -

I did a merge of the 1.2.0 code branch and the SVG branch (I think :-) ) on my machine and it can import SVG images. However - it's not that useful (yet). Perhaps I've misunderstood what that branch was - I had assumed that if I could import a SVG that the app could export it as gcode.

Here's a sample SVG for a truly impossible pancake:
https://dev.w3.org/SVG/tools/svgweb/samples/svg-files/penrose-staircase.svg

If I manually edit the SVG so that I reverse the order of the items drawn - I get this:
penrose_pancake
Some elements are not quite right yet - but it's getting closer. What I can't do is use the controls in PancakePainter to fill in areas. And when I try to export the gcode I get an error.

I can't be certain that I've done the merge correctly but I can go over that more carefully. I guess I have three questions:

  1. Is the SVG branch something that would (with a bit more work) be able to generate gcode?
  2. If the answer to Create tickets for all tasks within milestones - [1] #1 is yes - then will I have to re-order the drawing order within SVG so that the lines are drawn in the correct order?
  3. And - how should I modify the SVG so that I can do a flood fill with them?

I've added the *.pbp file as a *.txt since this interface won't let me upload a *.pbp.
Pancake Project.txt

Thanks for any help. This is certainly a very fun device.

Sean

@techninja
Copy link
Collaborator

Just so it happens, the official SVG import is what I'm actually working on right now. The work done by @daniellmb was a good start, though was merged into a testing branch a bit prematurely, and there's numerous parts of the GCODE rendering that assume too much about the structure of the data on the layer to allow direct SVG importing without tons of cleanup. It's certainly possible and has been done with similar code, but it needs more work.

If you want it to get it to work, just work with importing simple outline paths without fills, and use the flood fill on those, and make sure and click to set the color for every single path (this also sets its data color index, read by the GCODE renderer). If you still run into issues, feel free and debug the GCODE renderer, it's just a bit of string juggling and really not to complex, with a little knowledge of Paper.js. Good luck!

@techninja techninja added enhancement 🚀 New/enhanced functionality or out of scope improvements drawing 🖌️ User interface for drawing or creating art user experience 👨‍🎨 Anything involving user interface/buttons/experience deprioritized 👇 Not a current StoreBound priority, community progress only labels Feb 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deprioritized 👇 Not a current StoreBound priority, community progress only drawing 🖌️ User interface for drawing or creating art enhancement 🚀 New/enhanced functionality or out of scope improvements user experience 👨‍🎨 Anything involving user interface/buttons/experience
Projects
None yet
Development

No branches or pull requests

2 participants