alexqzd / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. | Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
http://marlinfw.org
GNU General Public License v3.0
198 stars 70 forks source link

Update Gcode preview to use PyQt6 with Cura 5 #27

Closed Archer4499 closed 2 years ago

Archer4499 commented 2 years ago

Description

Imports and uses PyQt6 instead of 5 if used with Cura version 5. Based on changes in https://github.com/mriscoc/Ender3V2S1/commit/fd215454c21c3b3afecca522e6141f52576aa4c7

Benefits

Allows the preview image generator to work with Cura 5

Configurations

N/A

Related Issues

N/A

Archer4499 commented 2 years ago

As a side note, the OctoPrint plugin Slicer Thumbnails doesn't pick up these preview images because of the jpeg in the header. Would it be a good idea if I were ask them to add that, or is there an alternate solution you'd recommend?

Since it does process the preview if I remove the word in the gcode, I assume it would just mean adding an optional jpeg to the regex line below: https://github.com/jneilliii/OctoPrint-PrusaSlicerThumbnails/blob/558d20c3f4477e75f9cfb488a74fbc6eff1d948f/octoprint_prusaslicerthumbnails/__init__.py#L68

alexqzd commented 2 years ago

Since it does process the preview if I remove the word in the gcode

I added the jpeg part because I thought it would mess with octoprint so I guess I could safely remove it in the next release :)