Jump to content

SVG Toolpath Reader - size? mm?


greens83

Recommended Posts

Posted · SVG Toolpath Reader - size? mm?

Hello,

 

Hoping someone can shed some light on this for me. I have drawn a toolpath in adobe illustrator at the exact size I want it (in mm) 

However when I open the SVG saved from illustrator into Cura it is significantly smaller. 

Does anyone know what Cura/SVG Toolpath Reader identifies as the dimensions/units of the SVG file? It says on GitHub its mm, but it is definitely not coming in as mm. The Illustrator file is definitely drawn in mm. Artboard set too mm. Rulers confirm outer dims are exactly as I want them.

 

Any suggestions or info would be very much appreciated.

  • Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    Well the error is hopefully EXACTLY 25.4X and if you click on the part and set the scale tool to 2540% and that gets it close then it's probably exactly that.  Also often it is off by EXACTLY 10x.  So try those 2 scales and hopefully that will explain a lot.  If it's too small by 25.4 then illustrator is probably switching to inches at the last second when it saves the file.  If it is off by 10X then illustrator is probably switching to cm at the last second when it saves the file.

    • Like 1
    Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    Hi, thanks for the reply. I cant manually scale the toolpath in cura. There is no option to do that. The scale looks to be about 20% too small. Weird. All I can do is make it too big to start with but I have no way of knowing by how much!

  • Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    I can see in the svg file (via notepad) that the viewbox is set to the size of the build plate (223 x 223)

    width="223px" height="223px" viewBox="0 0 223 223"

    So all I can assume is that the svg toolpath reader plugin is somehow reading 223 not as 223mm but as another unit or has some conversion factor? or something I dont understand about svg files is dictating the size.

     @ghostkeeper can you help me out here please?

  • Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    Ok through trial and error I got it to come in at the right scale. If anyone else runs into this with svg form adobe illustrator here's what I did.  Save as - SVG, tick use artboards. settings here:

    396405671_Screenshot2021-11-0817_04_59.thumb.png.9749ecd6332ca35f42381e879bde8513.png

    No idea which ones made it come in as scaled. It was just trial and error.

     

     

    • Thanks 1
    Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    Admittedly, it's hard to get right. This is where the scale is determined (in particular the unit_w and unit_h variables, determining how big each unit length of the SVG will be IRL): https://github.com/Ghostkeeper/SVGToolpathReader/blob/b12fc84aad90f2d4a9dac00d1c676b47dda4b0d8/Parser.py#L1352-L1372

     

    In effect, the viewBox property determines how big the image should become, in millimetres. The image width and height determine how it should scale the image to be in that viewbox. It doesn't do any clipping.

     

    Looking at this now, it does seem to be somewhat different than how SVGs are normally rendered on a screen. This may need some fixing, if you can post an example in Github Issues of an SVG that goes wrong: https://github.com/Ghostkeeper/SVGToolpathReader/issues

  • Link to post
    Share on other sites

    Posted (edited) · SVG Toolpath Reader - size? mm?

    Thanks for the response @ghostkeeper

    I tried to attach svg in github issues and here but neither accept the file type. I'm not sure If this problem is limited to Illustrator though. Lots of people complaining about the svg output on Adobe forums.

     

    Its such a useful tool with a lot of potential imo, thank you for making it available. Id love to see it better integrated into Cura though. It would be much more friendly If it could be used and displayed with other imported stl files over the top of the drawn toolpath so you can see how it will line up and dont have to cut and paste gcode. Another file format like dxf would be great too. I'm sure I'm asking for far too much and it would be a lot more complicated to implement than I realise!

    Edited by greens83
  • Link to post
    Share on other sites

    Posted · SVG Toolpath Reader - size? mm?

    I have figured out a better way to do what I wanted the svg toolpath to do and thought Id share.

     

    I drew my toolpath in autocad. I made sure the lines were a nozzle width apart. I then extruded the line into a surface (open polyline so it doesn't become a solid volume). Now I print using the 'surface' mode in cura. I use the per model settings to make this toolpath/extruded surface my first layer and then print whatever I want on top of it. Works perfectly.

    • Thanks 1
    Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • UltiMaker Cura 5.7 stable released
        Cura 5.7 is here and it brings a handy new workflow improvement when using Thingiverse and Cura together, as well as additional capabilities for Method series printers, and a powerful way of sharing print settings using new printer-agnostic project files! Read on to find out about all of these improvements and more. 
         
          • Like
        • 16 replies
      • S-Line Firmware 8.3.0 was released Nov. 20th on the "Latest" firmware branch.
        (Sorry, was out of office when this released)

        This update is for...
        All UltiMaker S series  
        New features
         
        Temperature status. During print preparation, the temperatures of the print cores and build plate will be shown on the display. This gives a better indication of the progress and remaining wait time. Save log files in paused state. It is now possible to save the printer's log files to USB if the currently active print job is paused. Previously, the Dump logs to USB option was only enabled if the printer was in idle state. Confirm print removal via Digital Factory. If the printer is connected to the Digital Factory, it is now possible to confirm the removal of a previous print job via the Digital Factory interface. This is useful in situations where the build plate is clear, but the operator forgot to select Confirm removal on the printer’s display. Visit this page for more information about this feature.
        • 0 replies
    ×
    ×
    • Create New...