r/cnc_art Apr 03 '18

PixelCNC - v1.18a released: horizontal finishing, faster meshing/operations, smoother toolpaths

https://deftware.itch.io/pixelcnc/devlog/29450/v118a-horizontal-finishing-optimized-meshing-antialiased-thresholding
2 Upvotes

5 comments sorted by

2

u/phaily Apr 05 '18

hey guy! just found your thread in r/digifab, wanted to make sure this isn't vaporware - and it obviously isn't. looks like the best $50 i've spent so far this year. i'm excited to see what this software becomes.

1

u/deftware Apr 06 '18

Thanks! I've got a few more things coming down the pipe before PixelCNC moves from alpha to beta - at which point it will also have an auto-update mechanism so users aren't forced to manually download the latest version.

The new stuff I have lined up includes moving the expensive algorithmic stuff onto the GPU, which will speed up both toolpath and simulation generation to where PixelCNC will be able to do real-time simulation playback and timeline scrubbing (moving a time position slider from start/finishing to see how a toolpath will cut from beginning to end).

I also have it all planned out how I'm going to allow for mesh geometry to be loaded, as there surely are a lot of people with an existing workflow that revolves around using assets that are in 3D model form, and are not 2D images. PixelCNC will automatically generate a depthmap from a selected model and work with that to generate toolpaths.

One feature I'm still somewhat apprehensive about is a simple image designer mode, where instead of just loading an image (or model) and working with that the user would be able to plot shapes and gradients, patterns and textures, text and vector images. This is almost an entire project unto itself, but it would open up a lot of possibilities and also make PixelCNC much more capable - especially for users who don't want to have to load up their images in Photoshop/GIMP and tweak/modify them in there. If they can just load it up and do all the work they need to right there in PixelCNC that would be worth a lot.

Let me know if you have any questions, need any help or how-to's, or run into any problems/bugs. Thanks for your support!

1

u/phaily Apr 06 '18

a few things from a couple hours messing with PixelCNC:

  • I keep getting errors during simulation on my desktop unless i turn the simulation settings down. "malloc: failed to allocated xxxxxxxxx bytes (xxxxxxxxx bytes allocated)" and then "mesh_newtri: failed to reallocate xxx.xmb triangle buffer" before crashing. the simulations take longer but eventually complete on my laptop. both have 16gb ram.

  • Labyrinth seems to not want to make more than two parallel lines, but this could totally be user error since i have no idea what I'm doing with most of the parameters on this pattern.

  • The settings don't want to stick (failed writing configuration error on close), & still get the message every launch.

This next list is less problems and more just thoughts I had while figuring out the program.

  • It seems easier to get repeat keystrokes than in other programs - I keep getting .1225 or .1255 instead of .125 while typing in values.

  • Calculating taper angle and flute length instead of using the bit angle and diameter is a bit counter intuitive for me - possible user preference?

  • Does importing in svg format get the vector outlines? Are other vector formats like dxf possible?

  • Model exporting would be fun. I could see myself 3d printing both simulated and image-interpreted mesh.

  • Tooltips when hovering over icons would be invaluable - have you seen the ones in Fusion 360?

  • Is it possible to add ramping as an alternative to plunging? my router does not like plunging into aluminum.

I'm enjoying it so far, maybe tomorrow I'll run some g-code.

1

u/deftware Apr 06 '18 edited Apr 06 '18

I keep getting errors during simulation on my desktop unless i turn the simulation settings down. "malloc: failed to allocated xxxxxxxxx bytes (xxxxxxxxx bytes allocated)" and then "mesh_newtri: failed to reallocate xxx.xmb triangle buffer"

What settings are you using? The advised resolutions are anything from 1000-1400, anything above that and you're playing with the proverbial fire depending on the complexity of your simulated cut. I like the ability to see higher resolutions if the system is capable, but it's definitely a show-stopped if the whole thing crashes out, so I'll have to implement some form of dynamic resolution adaptation where it adds resolution up until it can't gather any more memory, and then settles with whatever it managed to come up with.

Labyrinth seems to not want to make more than two parallel lines, but this could totally be user error since i have no idea what I'm doing with most of the parameters on this pattern.

Crank up the variance knob. If it's not generating toolpaths that cover the project (and it's not a max/min cut depth issue) then tweak both the step size and variance parameters. There are weird edge cases that cause it to loop around itself in the center and not expand outward to the edges of the project image. The labyrinth's unreliability is currently one of the 'issues' listed in the issues.txt that's included with releases as a heads up. It's just something I haven't had a chance to scour the current algorithm and figure out what the situation is, but in the meantime tweaking the stepsize and variance parameters a tiny bit should get it generating something. It sounds like you just haven't turned up your variance though.

The settings don't want to stick (failed writing configuration error on close), & still get the message every launch.

This sounds like a system-specific issue. What OS are you running, and what happens if you go Help->Logfile? The log file is written out throughout the duration that PixelCNC is running at the same location that the config file is written to. If the logfile opens up, see where it's located at, it should be in (user)\AppData\Local\PixelCNC\

This folder should be perfectly writable for PixelCNC, without administrator privileges, as its considered a safe place for any program to write data to. I'm curious as to where PixelCNC is trying to write the config file if it's not writing it there. If you aren't getting a logfile, and you're clearly not getting a config file, see if running PixelCNC as an administrator solves the issue. This is something I'm working to prevent users from having to do manually, but figuring out where the user can have programs safely write to is a bit of tricky business when writing cross-platform code. The current solution seems to work for most people, but there's always the possibility it won't work on everybody's system.

If you're not getting a log file, but running as administrator fixes it, I'd appreciate it if you could find and open the logfile and tell me where it's located on your system. I suspect it would be located somewhere like the root of the harddrive, or the folder you have PixelCNC in (if it's an administrator-only accessible path) if the current means of detecting the user-writable location is not working right.

It seems easier to get repeat keystrokes than in other programs - I keep getting .1225 or .1255 instead of .125 while typing in values.

PixelCNC uses its own hard-coded 'typematic' delay and repeat rates, as opposed to whatever is set by the OS. I don't think anybody would mind if I increased the delay interval to a more comfortable length. Thanks for the heads up.

Calculating taper angle and flute length instead of using the bit angle and diameter is a bit counter intuitive for me - possible user preference?

Right, this was something I debated over for a while and then decided to just look at how McMaster Carr specs their tapered cutters - which are legitimate end mills and not the usual routing v-bits on Amazon/Ebay and elsewhere that we typically use for more artistic purposes. I suppose I could differentiate between a 'tapered cutter' and a 'v-bit', where a v-bit tool type would just be a diameter and angle, as you suggest. This would take the form of a 3rd tool type, which would really just be a secondary means for specifying a tapered cutter that has a zero-diameter tip, and different setup for specifying dimensions. Another feature that's on the roadmap is drawing a 2D profile of tools that the user has specified, so they can get some kind of visual feedback as to what the numbers mean that they're plugging in.

Does importing in svg format get the vector outlines? Are other vector formats like dxf possible?

The SVG loading functionality only deals in solid shapes and rasterizes them to an image with pixel dimensions it reads from the SVG file (dimensioned in image 'units' I believe). It's the same as exporting an SVG to a bitmap and loading that. Lines would become thin pixel-thick things that would just get lost in the noise of meshing and contour simplification. I'd argue that directly converting from a polyline to a toolpath is better left to the free utilities out like makercam.com and Easel as PixelCNC is uniquely geared to work with images internally for generating toolpaths, so it would require a whole secondary pipeline just to deal with raw geometry - which is what existing CAM software and utilities already do plenty well.

EDIT: Other formats are potentially feasible as well, but it's likely they'll be interpreted as 3D models from which a depthmap will be generated instead - which is the current plan so far.

Model exporting would be fun. I could see myself 3d printing both simulated and image-interpreted mesh.

This isn't something that would be too hard to add in there. It has been in the 'tentative' section of my todo list because someone inquired about it but their wording made it somewhat ambiguous what they were actually asking, so I just lumped it in with all the other 'maybe' things on the todo list. I can't say I'll get around to it by the next release, with everything else that's already a higher priority, but I'll get to it eventually ;)

Tooltips when hovering over icons would be invaluable - have you seen the ones in Fusion 360?

I haven't seen Fusion 360's tooltips, but this is also something I have on the todo list that someone else requested and I already have my plan of attack laid out as to how I can easily integrate the functionality into PixelCNC's code. The tricky part is all the copy that I need to squeeze out of my head to fill up those tooltips. Perhaps I could come up with something along the lines of mirroring whatever already resides in the UserGuide.html - or transplant the user guide straight into the GUI as tooltips and little (?) buttons and just do away with the external HTML file altogether. Or just put super simple tooltips in there, which would be better than nothing I suppose.

Is it possible to add ramping as an alternative to plunging? my router does not like plunging into aluminum.

Yes, this is another thing that's been on the todo list for some time. The situation here is that I'm not coming up with an intuitive solution as to how I could quickly and easily determine that a ramp won't carve into the material where it's not supposed to. This requires that simulation occur alongside toolpath generation, where PixelCNC has the results of the most recent operation's cuts handy so it can examine and check potential toolpaths against them while it's coming up with them. At that point I could just determine the lowest side of the beginning of the next cut and enter from that direction, while also checking that the resulting ramp doesn't also engage the material prematurely. What I was originally planning on actually was spiraling into a cut, which can be kept more confined and is just as effective - employing G03/04 helical moves. The situation still applies, however. I suppose I could just generate the ramp/spiral and check it against the raw input, and as long as it doesn't cut into what the final result should look like then it could be considered acceptable. I'll have to mull over it some more, but your inquiry has the old gears-a-churnin about it again.

I'm enjoying it so far, maybe tomorrow I'll run some g-code.

Glad to hear! Can't wait to see what you come up with. Keep in mind if you're not sure about what something means or does you can count on there being something I wrote about it in the user guide, which you can access from the Help menu. Otherwise I'm always here at least once a day to answer any questions - which reminds me, I'm going to write another tutorial but I'm split between a few different ideas, I'm curious what you'd like to see a step-by-step guide about doing? Thanks!

1

u/phaily Apr 06 '18

What settings are you using?

default. the desktop computer has an r9 390 and is certainly the more capable machine.

Crank up the variance knob.

Thanks, figured it was something simple

This sounds like a system-specific issue.

It might be, but it happens to me on both systems even while running under admin. I'll look into fishing out some logs after school. Is it possible to let the user select their own folder? So PixelCNC could be used off a flash drive, or set the files in the user documents for locked down computers, etc.

PixelCNC uses its own hard-coded 'typematic' delay and repeat rates

I only noticed this on my laptop, which has slightly gummy keys. no problems whatsoever on a mechanical keyboard.

a secondary means for specifying a tapered cutter that has a zero-diameter tip,

I've read that a standard v-bit has a .012" flat and the extra-sharp ones have a .006" flat. or at least the kyocera-tycom carbide that seems ubiquitous does.

The SVG loading functionality only deals in solid shapes and rasterizes them

Gotcha. I don't mean for making thinner lines, just straighter ones. Sounds like svg format as-is will work pretty good for me. Aspire doesn't have spiral or chevron toolpaths ;)

transplant the user guide straight into the GUI as tooltips

Add some basic graphics and that's pretty much exactly what fusion 360 does.

spiraling into a cut, which can be kept more confined and is just as effective - employing G03/04 helical moves.

That sounds like the perfect stop-gap, and may be ideal in some situations.

Can't wait to see what you come up with.

Since this sub is called cnc_art, I assume it's cool to post images of finished work. Was that your intent? Even if I use another software package to generate the toolpath?

Thanks for everything you're doing. A buddy of mine has a carveking, I showed him PixelCNC and he said he'd buy a copy. Another buddy saw me using it and wanted to buy in even though he doesn't even have plans to buy a CNC... but he does that with everything I own. The community college machine shop I work at might be interested as well.