-
Notifications
You must be signed in to change notification settings - Fork 1.2k
DRAFT: Converting Gcode graphics to use shaders #3547
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
base: master
Are you sure you want to change the base?
Conversation
|
Thanks for doing this. I admit that I have never looked at the preview code (except in passing to fix an arc bug) and hadn't realised that it was using deprecated calls. There may be some scope for confusion in the naming as "canon" as that also refers to the "canonical" motion commands in emccanon. (But this comment is in the context of not looking at the code as I am camping in a field at the moment) |
|
On second thought have the update loop internal to the graphics code would mean you can't customize performance per machine. That should reduce the cpu usage. I personally don't like the current controls in gcodes graphics in particular right click zoom. I'm open to name suggestions, CanonShade is a mixin from Canonmodule.cc in rs274. CanonShaders... could make it like something to do with shaders/opengl/and drawing. I need to update my dev machine as the C++ upgrade made this challenging, did most of this on an actual mill. So I'll probably do that today and keep working on improving this |
|
I should have been specific, the rotation with the mouse only rotated in one direction rather then back and forth with the mouse pad. I way more generic way to select controls would be a nice touch. Maybe we could get gestures one day too. |
|
|
I assume this is still a draft? |
|
Maybe have a look at QTpyvcp's vtk based backplot: |
|
Welp. I no longer have a job that allows me work time to develop LCNC anymore. I can take this down for the meantime. I might be able to get back to it when the snow falls. VTK looks interesting... I see lots of references to it being high memory intensive which large cam files take a ton of memory already. If someone is going to take on this torch.. I think gcode.parse_file needs to be split into a parse n lines of code so visually you can render a bit at a time and not lock the display up rendering millions of lines of code. linuxcnc/src/emc/rs274ngc/gcodemodule.cc Line 855 in f7405d5
I know I didn't contribute much to the project, but its still been a fun 6 years. |

Working on a minimum viable product. The old GL pipeline has been deprecated for some time and now sometimes when gcodegraphics.redraw() gets called I get a black triangle across the display.
The "Modern" pipeline (Circa 2004) using shaders seems to be a valid option to upgrade to. Needs a little bit of polishing yet, but working to get the feature set that was existing first.
This also allows for moving into constructive solid geometry which could render stock and then subtract tool paths, rendered on the GPU.
Going to keep working on this but was wanting feedback before going to far.
Some Philosophy here: