7768 Commits

Author SHA1 Message Date
Nino van Hooff
ddd7d15287 Attempt to appease mypy 2020-03-26 09:45:26 +01:00
Ghostkeeper
986284052d
Show warning on any invalid pixel, not just 10
Now that we have no noise any more we can do this.
Possibly cuts the processing time in half, too.

Contributes to issue CURA-7262.
2020-03-25 18:57:30 +01:00
Ghostkeeper
4c770587e2
Fix getting additional bytes from QImage
QImage's bytes are aligned to memory words per column of pixels. That means that one of these columns contains 99% valid image data, but with several bytes of unassigned noise at the end. How many of these padding bytes there are would depend on the image size, i.e. Cura's window size. In the end, the total number of bytes in the image ends up slightly more than w*h*3. As a result, Cura would crash because it couldn't reshape the image. Reshaping was completely unnecessary anyway, but this random noise was giving false positives also.
But how do you then get only the actual pixels from each column of data? We can't just go iterating over this array, as that would be an iteration of thousands of columns which is prohibitively slow in Python. No, we're going to do some Numpy magic. We're going to create a class that pretends to be a Numpy array. Give this class some data and say that this data has a certain pixel size but also a certain STRIDE LENGTH. This stride length can be the length of the actual pixel data. As a result when Numpy sees this object it will read out the data using these strides, all done efficiently within the C code of Numpy.

Framerate is fantastic on my computer. No problems at all. Pretty powerful computer though. But also a big 5k screen. Still no problem for Numpy. Seems to be decently efficient.

Took me quite a while to figure all of this out.

Contributes to issue CURA-7262.
2020-03-25 18:00:14 +01:00
Nino van Hooff
3bb3b69082 Attempt to appease mypy 2020-03-25 17:32:41 +01:00
Nino van Hooff
92f278acc8 Change trusted scripts path from resources to plugin/scripts
CURA-7319
2020-03-25 16:54:43 +01:00
Nino van Hooff
6bf00d7ea1 Merge branch 'master' into ppscript_pre_secure 2020-03-25 16:25:44 +01:00
Ghostkeeper
a4fbf3c613
Move X-ray set-up code into _checkSetup
That's what that function is meant for. It's executing essentially the same, since before it was executed right after the call to _checkSetup() and now it's at the end inside that function.

Contributes to issue CURA-7262.
2020-03-25 15:13:33 +01:00
Jaime van Kessel
dec68002bc
Use patch.object to temporarily replace mock a function call
CURA-7319
2020-03-25 12:35:15 +01:00
Jaime van Kessel
d5b58cf3b4
Add missing typing 2020-03-25 11:47:38 +01:00
Ghostkeeper
2b003c30dc
Catch PermissionError when writing workspaces
We'll want to give a proper error message then. We have no mechanism right now to show a message on the screen particular to this error. Instead we'll let it fail (the user sees a message that writing fails) and put a message in the log why it failed.

Fixes Sentry error CURA-DK.
2020-03-25 09:12:14 +01:00
Ghostkeeper
0150f37937
Merge branch 'master' into xray_in_solid_view 2020-03-24 21:45:48 +01:00
Kostas Karmas
136fc90f48 Merge branch 'master' into CURA-7310_Template_export_inkection_call_custom_openUrl 2020-03-24 16:59:27 +01:00
Kostas Karmas
eaef9f0f45 Open plugin author page with custom openUrl
CURA-7310
2020-03-24 16:42:46 +01:00
Kostas Karmas
4f0f7dec5e Open material author page with custom openUrl
CURA-7310
2020-03-24 16:42:22 +01:00
Kostas Karmas
92cef02ee5 Open "buy material spool" with custom openUrl
CURA-7310
2020-03-24 16:38:25 +01:00
Kostas Karmas
e003d76c1e Open links in materials with custom openUrl
CURA-7310
2020-03-24 16:36:09 +01:00
Nino van Hooff
c0d2977f4d Cleanup test_enterprise_signed_user_script_allowed
CURA-7319
2020-03-24 16:28:43 +01:00
Nino van Hooff
5b045f89b1 Finish postprocessing script signature checking
CURA-7319
2020-03-24 16:24:24 +01:00
Nino van Hooff
7f89c7e740 Merge branch 'master' into ppscript_pre_secure 2020-03-24 11:37:53 +01:00
Remco Burema
c20b2c6ee0
Merge pull request #7211 from Ultimaker/CURA-7150_proper_http_request_headers
CURA-7150_proper_http_request_headers
2020-03-24 11:25:07 +01:00
Nino van Hooff
1a4cb49eba Hide upload message progress when upload is done
CURA-7150
2020-03-23 11:17:32 +01:00
fieldOfView
ca7a4b4779 Disable user "unchecking" mesh type in per model settings panel 2020-03-22 19:21:41 +01:00
Nino van Hooff
96d1e6385d Merge remote-tracking branch 'origin/CURA-7150_proper_http_request_headers' into CURA-7150_proper_http_request_headers 2020-03-20 17:34:12 +01:00
Nino van Hooff
6db8a9ec3e Set progress of backup message to 100% when done
CURA-7150
2020-03-20 17:31:54 +01:00
Nino van Hooff
72a66f1358 Do not use the JsonDecorator scope for binary downloads
CURA-7150
2020-03-20 17:31:21 +01:00
Ghostkeeper
5cfe71e516
Fix binding loop in action panel widget
This widget can't set its width to the width of its children, since its children anchor to its right-hand side which depends on the width.
This fixes the following warning in the log:
2020-03-20 14:25:20,351 - WARNING - [MainThread] UM.Qt.QtApplication.__onQmlWarning [406]: file:///home/trin/Gedeeld/Projects/Cura/plugins/PrepareStage/PrepareMain.qml:16:5: QML ActionPanelWidget: Binding loop detected for property width

Done during Turbo Testing and Tooling.
2020-03-20 14:52:33 +01:00
fieldOfView
fa613c35eb Hide unused temperature for Repetier 2020-03-20 13:39:00 +01:00
fieldOfView
c87ee61e9c Add repetier-specific parking if repetier flavor is selected 2020-03-20 13:35:48 +01:00
fieldOfView
87633e7818 Make Griffin a selectable method instead of snooping it from gcode 2020-03-20 12:56:07 +01:00
fieldOfView
c4d1ab4ff1 Merge branch 'master' into feature_unify_pause_at_height 2020-03-20 11:40:04 +01:00
Ghostkeeper
c7e6553dbf
Disallow printers larger than 2km
To do this, I'm giving more power to the NumericTextFieldWithUnit QML element, to allow an arbitrary minimum and maximum. Enforcing this minimum and maximum is fairly simple with a JavaScript hook. This hook is necessary because the DoubleValidator allows intermediary values which defeats the purpose, essentially allowing any number as long as it has the correct number of digits.
Printers larger than 2km would start to give overflow errors in its X and Y coordinates. Z is okay up to about 9 billion kilometres in theory, since we don't need to do any squaring math on those coordinates afaik. In practice I'm doing this because at very high values the Arranger also gives errors because Numpy can't handle those extremely big arrays (since the arranger creates a 2mm grid).

Fixes Sentry issue CURA-CB.
2020-03-20 11:16:16 +01:00
fieldOfView
a7e23ba99e Use an appropriate default for the pause method...
based on the machine gcode flavor and machine name
2020-03-20 10:54:43 +01:00
fieldOfView
4994eb291e Merge branch 'master' into feature_unify_pause_at_height 2020-03-20 10:06:25 +01:00
fieldOfView
7f6a39d7d0 Fix loading comments in gcode snippets from 3mf projects
Fixes #7304
2020-03-20 09:26:31 +01:00
fieldOfView
469c205384 Fix typo 2020-03-20 07:42:01 +01:00
fieldOfView
65346d9200 Store/retreive SceneNode in/from <object> attribute 2020-03-20 07:28:48 +01:00
Nino van Hooff
6f4276c5cc Fix mypy issue in CreateBackupJob
CURA-7173
2020-03-19 12:30:14 +01:00
Nino van Hooff
7f6afb9638 Show error backup exceeds maximum backup size and log event to sentry
CURA-7173
2020-03-18 17:17:36 +01:00
Jaime van Kessel
8a7823e49b
Merge branch 'fix_3mf_file_watcher' of https://github.com/fieldOfView/Cura 2020-03-18 12:51:53 +01:00
Jaime van Kessel
4e8da5d7fd
Add missing typing
CURA-7150
2020-03-16 17:20:59 +01:00
Jaime van Kessel
56c387502a
Strip extension from file_name when printing via the cloud
ST-2880
2020-03-16 15:54:41 +01:00
konskarm
3d054a9400
Merge pull request #7223 from Ultimaker/CURA-7255_infill_only_dropdown
CURA-7255_infill_only_dropdown
2020-03-13 10:30:09 +01:00
Nino van Hooff
96ed85f9c0 Move UltimakerCloudAuthentication and UltimakerCloudScope
...to their own module
Fixes an import error where UltimakerCloudScope was used my both the
Toolbox and CuraDrive plugins

CURA-7150
2020-03-12 17:48:54 +01:00
Nino van Hooff
2e7b47f1ea Add None-check for download url
CURA-7150
2020-03-12 17:21:03 +01:00
Nino van Hooff
6dd8ebb06a Process review comments in Cura project
CURA-7150
2020-03-12 17:06:33 +01:00
Nino van Hooff
2625bbef44 Changed pos infill only label per suggestions by Tim and Yi-An
CURA-7255
2020-03-12 14:01:03 +01:00
Nino van Hooff
61af28c681 Process review comments.
CURA-7150
2020-03-12 13:57:09 +01:00
Nino van Hooff
ce12827879 Fix infill mesh defaults not visible when changing per object settings
The problem: When infill mesh is set, wall_thickness and
top_bottom_thickness are added to the settings. Then these settings are
set to visible on the visibility_handler.
It appears however, that the visibility_handler considers all added
settings to be visible. It thus concludes that no UI update is necessary
because the settings are already added.
2020-03-12 13:25:29 +01:00
Nino van Hooff
d11b3b0921 Extra comment for RestoreBackupJob 2020-03-10 14:23:40 +01:00
Nino van Hooff
ebfad16508 Refactor the restore backup implementation to RestoreBackupJob 2020-03-10 14:21:52 +01:00