Skip to content
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

Increase the lines searched for PNG image #3954

Open
wants to merge 223 commits into
base: master
Choose a base branch
from

Conversation

dunkmann00
Copy link

Only effects plaintext gcode. The new QOI images make it necessary to look further into the gcode to find the PNG image for display in Prusalink (and maybe Prusaconnect? I've not used it so not sure).

Currently, if you have a plaintext gcode file with the default gcode thumbnails (for MK4 that means: 16x16/QOI, 313x173/QOI, 440x240/QOI, 480x240/QOI, 640x480/PNG) Prusalink can't load the thumbnail, because the printer fails to send it.

This fixes prusa3d/Prusa-Link-Web#475

Tomcus and others added 30 commits March 28, 2024 12:20
We don't have consent from the user right now and they are not
encrypted. Shouldn't go to "production".

BFW-3468.
Dialog stores the state of underlying screen upon construction
and loads it back upon destruction. Consistently. Like, always.

Without this, ToolBox::DialogToolActionBox would set focused item
which would prevent menu screen from serializing its focused item.
Allow them in redscreen/redscreen.

It's already sent proactively, so it's safe.

BFW-5207.
Show Enclosure menu only if enclosure is active
Change string describing invalid temperature from "N/A" to "--"
Transfers were not cleaned up ever, if in print preview when finished,
this was caused by wrongly detecting if the transfer is in progress. It
did not check, if the backup file was there, do transfer, where backup
file was not present (finished) were taken as in progress.
CZDanol-prusa and others added 26 commits April 11, 2024 14:29
The valued that is moved from is invalidated to not reset values at the
end of its lifetime.

BFW-5322
This should prevent noices when calibration X axis on XL and improve
Tool Offset Calibrations, but only when run as part of selftest, not as
gcode (will be done in separate commit/PR)

BFW-5322
We shouldn't run any selftest with phasestepping enabled. To prevent
running G425 with phase stepping we are disabeling phasestepping
temporarily in the gcode it self instead of the selftest state machine.

This improves Tool Offset Calibration results when running said
calibration on already calibrated machine. The results are not perfect
yet. But this change removes the major inaccuracies in the measurements.

BFW-5276
We noticed shifts in measured data. Recomend reading BFW-5276 for more
details, but in the end slowing down the parking speed helped a lot.

BFW-5276
Fill will be in the next commit

BFW-5335
The problem was in write_end_item calling migrate_bank.
The function is called in store init, where migrate_bank would screw things.
In other cases, the free space for the end item is checked
in the parent calling functions.

BFW-3553
This reverts commit f605a28bea662f02ec8d5121f4f57cee8ada774b.
Copy pasted from standard printing screen

BFW-5371
Only effects plaintext gcode. The new QOI images make it necessary to
look further into the gcode to find the PNG image for display in
Prusalink.
@danopernis
Copy link
Member

Thank you for the contribution. I looked into prusa3d/Prusa-Link-Web#475 and tried your fix on the file they provided. It works for the large preview, but doesn't work for the small thumbnails.

The thing is, thumb/s/ API endpoint looks for images of exactly size 16x16 and type PNG and those are completely missing from the sliced file. While this fixes the issue with the large thumbnail, all the small thumbnails suffer penalty for searching the nonexistent thumbnail, as we are now searching twice the lines.

I would much rather ditch entire PNG support and let PrusaLink render the QOI files, perhaps using https://github.com/kchapelier/qoijs but that is a much larger change.

I am leaving this open and will discuss this more in the team.

@dunkmann00
Copy link
Author

Okay, sounds good. I hadn't realized about the small thumbnails. Where are those shown on PrusaLink?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Thumbnail generation not parsed by PrusaLink