[Plugin] PrettyGcode viewer

This plugin is incredible. It loads on my iPhone with Fat Lines and AA enabled. It loads more quickly than the standard Gcode viewer.

Also it's pretty interesting a modern iPhone GPU seems to run it better than a intel 620 integrated graphics.

Webcam is also no longer working in my PGC :confused: Any update on this? I'm going to do some re-installing to see if that helps fix the problem...

Hello,

Those who are using this plugin. Can this run on a Raspberry Pi 3b+ effectively? I mean without causing any slow in the printing itself?

I like to install this and try it out but I don't want to zits or blob on my prints as a result...thx.

It's majority client side processing, all rendered in your browser - so it is more the machine you are using to access OctoPrint than the server.

I see. Thank you.

1 Like

But if you use a (touch)screen on the Raspberry Pi running OctoPrint and showing the web interface, this plugin will likely cause slowdowns.

1 Like

Hi everyone. I am coming back to PrettyGCode after some time working on other projects. I am going to be fixing some bugs and adding a new feature.

As far as bugs go, I see the camera isn't working anymore. I use the camera view that is in the "Control" tab and apparently that is now disabled if the Control tab doesn't have focus. Is this new behavior or did I break something?

For the feature, I need an easier way to preheat my bed and nozzle to prepare for printing. So I am going to add a basic temp display and the ability to set the nozzle and/or bed targets.

Having temps on screen is useful for for me in determining if something is going wrong (heater fail or thermal runaway). But I don't see a compelling reason to add fan speed. Not enough to clutter up the UI further anyway. Anyone have a good argument for it being on screen?

This is the look I am going for. Nozzle on top, bed on bottom. Adding pip marks for targets.
image

I think that's been that way for a while. You can hook into the onTabChange event to override the enable webcam function, I've done it for a couple of plugins. Also, onBrowserTabVisibility change as well.

and

hope those examples help.

The second example makes sense as far as enable/disable webcam. I wasn't aware of onBrowserTabVisibilityChange. Is this what happens when I switch tabs in like chrome rather than the tab in OctoPrint?

The first example I am not sure I follow. I already have a onTabChange where I do some camera enable/disable stuff. And I can add the enable/disable code from the second example. Correct?

Looks like there is also an issue if the camera view needs to be rotated. In the past the CSS to rotate the image was not specific. Now it applies only to a container with id "webcam_container". How did you deal with that (if at all)?

exactly, or if you minimize the browser and open it back up completely as well.

Yes, I believe so. I'm using an if check in that to know if the webcamtab plugin is installed as well, but you might not need that part.

I haven't had to deal with that issue since I'm just moving tab content around, so whatever OctoPrint is rendering is already handled.

I'm also having issues with the webcam view. My issue is particularly interesting. If I connect to Octoprint via PC A (Windows 7, latest Chrome), the webcam no longer works. It used to. Connect via PC B (W10, latest Chrome), it works. Like, I can run it on both at once, and one PC works and one doesn't. The icon is different on the W10 PC tho - it looks like an instamatic on the PC that works and like a DLSR on the one that doesn't. Hope this helps. Amazing plugin!

New version 1.2.3 is out. It should fix the web camera issue and the double binding problem.

1 Like

Now that I've nailed the Consolidated Tabs conflight and PrettyGCode is working normally. I would like to know if I can find a way to make PrettyGCode publicly visible. I know that it can be Twitch Streamed though I haven't been able to successfully to do so.

I know there are considerations about making the interface itself public because of the Printer Control Buttons, as well as the File Manager. Is Twitch the only way, and possibly safest, to do this?

I use OBS Studio with the browser window to stream to Twitch and Youtube. You do have to use a special command line switch (--enable-gpu) in OBS to make the 3d view work. Info is in the instructions on the PGC tab in OctoPrint.

New version 1.2.4 is out. Adds support for Arc commands thanks to FormerLurker. Also a simple status bar that just contains temperature info for now.

2 Likes

Yay finally it supports arcs

Thank you, this is a really great addon! And it's working great so far with Cura and PrusaSlicer.

Hi everyone. I have a new version of PrettyGCode almost ready for release. This is a ground up rewrite and will have lots of new features. And unfortunately, new bugs. So, I could use a few testers before I do a wide release. If you are interested in testing PrettyGCode 2.0 let me know here or via PM.

Thanks!
K