Comments (6)
I probably need to come up with another parsing routine since it currently uses a regular expression match against the whole file contents. That's really overkill since the thumbnails are currently stored right at the very beginning of the file.
from octoprint-prusaslicerthumbnails.
This has to do with a change I requested in order to support also thumbnails in Cura which end with CRLF instead of LF like PrusaSlicer does.
After looking for a possible solution to remove the need for the replace I came up with this solution:
Replace :
regex = r"(?:^; thumbnail begin \d+x\d+ \d+)(?:\n|\r\n?)((?:.+(?:\n|\r\n?))+)(?:^; thumbnail end)"
With :
regex = r"(?:^; thumbnail begin \d+x\d+ \d+)(?:\n|\r\n?)((?:[^\n\r]+(?:\n|\r\n?))+)(?:^; thumbnail end)"
This allows supporting both LF and CRLF without the replace statement. From my tests the solution seems to produce the exact same outputs.
from octoprint-prusaslicerthumbnails.
What version of octoprint?
from octoprint-prusaslicerthumbnails.
What version of octoprint?
OctoPrint 1.4.0 running on OctoPi 0.17.0
from octoprint-prusaslicerthumbnails.
I think I may have just fixed this issue with the latest release. Please check it out and let me know, version 0..1.1. You may have to force a check in the bottom of Software Update in the Advanced section at the bottom..
from octoprint-prusaslicerthumbnails.
Perfect! 0.1.1 renders the big gcode file without issue. Thank you!
from octoprint-prusaslicerthumbnails.
Related Issues (20)
- Elegoo Neptune 3 Thumbnails HOT 1
- picture icon not showing up in 1.8.2, warnings about missing thumbnails (but shows them anyway) HOT 8
- Preview stopped working HOT 11
- Cached issues with ongoing Octoprint instances HOT 45
- Installation without Internet connection fails HOT 1
- PleASE DELETE. HOT 1
- Plugin does not recognize the image embedded in the gcode with S3D 5.1 HOT 1
- Here we go again....with a REQUEST HOT 9
- [Request] "Moveable" PROGRESS BAR position HOT 12
- Prusa MINIs new firmware is using QOI image format instead of PNG HOT 5
- update to 1.0.3 failed HOT 3
- [FeatureRequest] Current Print Thumbnail a static URL HOT 4
- viewing thumbnail in file list HOT 2
- cached thumbnails in `data` folder bloat backups HOT 5
- When disconnecting the printer with a file loaded (and thumbnail shown), file information disappears but thumbnail stays
- Extracted Thumbnail in Source GCode Path? HOT 12
- [Feature Request] Support Luban thumbnails HOT 4
- Version 1.01 tries to repeatly update. HOT 14
- Thumbnails not appearing HOT 2
- Randomly working on MacOS BigSUR HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from octoprint-prusaslicerthumbnails.