mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-09 14:55:03 -06:00
Add extra exception handling for UFPwriter
This commit is contained in:
parent
fae4138b79
commit
3ab0b5decf
2 changed files with 9 additions and 3 deletions
|
@ -85,8 +85,10 @@ class Snapshot:
|
|||
preview_pass.setCamera(camera)
|
||||
preview_pass.render()
|
||||
pixel_output = preview_pass.getOutput()
|
||||
|
||||
min_x, max_x, min_y, max_y = Snapshot.getImageBoundaries(pixel_output)
|
||||
try:
|
||||
min_x, max_x, min_y, max_y = Snapshot.getImageBoundaries(pixel_output)
|
||||
except ValueError:
|
||||
return None
|
||||
|
||||
size = max((max_x - min_x) / render_width, (max_y - min_y) / render_height)
|
||||
if size > 0.5 or satisfied:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue