diff --git a/cura/ConvexHullJob.py b/cura/ConvexHullJob.py index 9fb18981d3..b356cb15f1 100644 --- a/cura/ConvexHullJob.py +++ b/cura/ConvexHullJob.py @@ -47,10 +47,19 @@ class ConvexHullJob(Job): # This is done to greatly speed up further convex hull calculations as the convex hull # becomes much less complex when dealing with highly detailed models. vertex_data = numpy.round(vertex_data, 1) - duplicates = (vertex_data[:,0] == vertex_data[:,1]) | (vertex_data[:,1] == vertex_data[:,2]) | (vertex_data[:,0] == vertex_data[:,2]) - vertex_data = numpy.delete(vertex_data, numpy.where(duplicates), axis = 0) - hull = Polygon(vertex_data[:, [0, 2]]) + vertex_data = vertex_data[:, [0, 2]] # Drop the Y components to project to 2D. + + # Grab the set of unique points. + # + # This basically finds the unique rows in the array by treating them as opaque groups of bytes + # which are as long as the 2 float64s in each row, and giving this view to numpy.unique() to munch. + # See http://stackoverflow.com/questions/16970982/find-unique-rows-in-numpy-array + vertex_byte_view = numpy.ascontiguousarray(vertex_data).view(numpy.dtype((numpy.void, vertex_data.dtype.itemsize * vertex_data.shape[1]))) + _, idx = numpy.unique(vertex_byte_view, return_index=True) + vertex_data = vertex_data[idx] # Select the unique rows by index. + + hull = Polygon(vertex_data) # First, calculate the normal convex hull around the points hull = hull.getConvexHull() diff --git a/resources/i18n/de/fdmprinter.json.po b/resources/i18n/de/fdmprinter.json.po index 9ba0fdca1f..e9a04a21ff 100644 --- a/resources/i18n/de/fdmprinter.json.po +++ b/resources/i18n/de/fdmprinter.json.po @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Der Abstand zwischen der Düse und den horizontalen Abwärtslinien. Bei einem größeren Abstand haben die diagonalen Abwärtslinien einen weniger spitzen Winkel, was wiederum weniger Aufwärtsverbindungen zur nächsten Schicht zur Folge hat. Dies gilt nur für das Drucken mit Drahtstruktur." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Z Überlappung der ersten Schicht" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All model pieces above the first " +"model layer will be shifted down by this amount." +msgstr "Die erste und die zweite Schicht des Objekts überlappen sich in der Z-Richtung, um das verlorene Filament in dem Luftspalt zu kompensieren. Alle Schichten über der ersten Schicht, verschieben sich in der Z-Richtung mit gewähltem Abstand nach unten." diff --git a/resources/i18n/en/fdmprinter.json.po b/resources/i18n/en/fdmprinter.json.po index 9ee03631bb..4578306bfb 100644 --- a/resources/i18n/en/fdmprinter.json.po +++ b/resources/i18n/en/fdmprinter.json.po @@ -2483,3 +2483,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Distance between the nozzle and horizontally downward lines. Larger clearance results in diagonally downward lines with a less steep angle, which in turn results in fewer upward connections with the next layer. Only applies to Wire Printing." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Initial Layer Z Overlap" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "Make the first and second layer of the object overlap in the Z direction to compensate for the filament lost in the airgap. All models above the first model layer will be shifted down by this amount." diff --git a/resources/i18n/es/fdmprinter.json.po b/resources/i18n/es/fdmprinter.json.po index a3e79fa69a..2c1f044147 100644 --- a/resources/i18n/es/fdmprinter.json.po +++ b/resources/i18n/es/fdmprinter.json.po @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Distancia entre la tobera y líneas descendentes en horizontal. Cuanto mayor sea la holgura, menos pronunciado será el ángulo de las líneas descendentes en diagonal, lo que a su vez se traduce en menos conexiones ascendentes con la siguiente capa. Solo se aplica a la impresión de alambre." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Superposición de las capas iniciales en Z" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "La superposición entre la primera y segunda capa del objeto para compensar la pérdida de material en el hueco de aire. Todas las capas por encima de la primera capa se desplazan hacia abajo por esta cantidad." diff --git a/resources/i18n/fdmprinter.json.pot b/resources/i18n/fdmprinter.json.pot index b7c6f07b46..b8870ef252 100644 --- a/resources/i18n/fdmprinter.json.pot +++ b/resources/i18n/fdmprinter.json.pot @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "" diff --git a/resources/i18n/fi/fdmprinter.json.po b/resources/i18n/fi/fdmprinter.json.po index ad12060cea..cc402b0e54 100644 --- a/resources/i18n/fi/fdmprinter.json.po +++ b/resources/i18n/fi/fdmprinter.json.po @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Suuttimen ja vaakasuoraan laskevien linjojen välinen etäisyys. Suurempi väli aiheuttaa vähemmän jyrkän kulman diagonaalisesti laskeviin linjoihin, mikä puolestaan johtaa harvempiin yläliitoksiin seuraavan kerroksen kanssa. Koskee vain rautalankamallin tulostusta." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Z Päällekkäisyys Alkukerroksen" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "Tee ensimmäinen ja toinen kerros esineen päällekkäisyys Z-suunnassa kompensoimiseksi filamentti hävisi ilmaväli. Kaikki mallit yläpuolella ensimmäinen malli kerros on siirtynyt alaspäin tämän määrän." diff --git a/resources/i18n/fr/fdmprinter.json.po b/resources/i18n/fr/fdmprinter.json.po index 7a49440b04..f8e10fa5f4 100644 --- a/resources/i18n/fr/fdmprinter.json.po +++ b/resources/i18n/fr/fdmprinter.json.po @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Distance entre la buse et les lignes descendantes horizontalement. Un espacement plus important génère des lignes diagonalement descendantes avec un angle moins abrupt, qui génère alors des connexions moins ascendantes avec la couche suivante. Uniquement applicable à l'impression filaire." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "La première et la deuxième couche de l'objet se chevauchent dans la direction Z pour compenser le filament perdu dans l'entrefer. Toutes les chouches au-dessus de la première couce du modèle seront décalées de ce montant." diff --git a/resources/i18n/it/fdmprinter.json.po b/resources/i18n/it/fdmprinter.json.po index b0e04c4308..40b5e36916 100644 --- a/resources/i18n/it/fdmprinter.json.po +++ b/resources/i18n/it/fdmprinter.json.po @@ -2414,3 +2414,18 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "Indica la distanza tra l'ugello e le linee diagonali verso il basso. Un maggior gioco risulta in linee diagonali verso il basso con un minor angolo di inclinazione, cosa che a sua volta si traduce in meno collegamenti verso l'alto con lo strato successivo. Applicabile solo alla funzione Wire Printing." + +#: fdmprinter.json +#, fuzzy +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Z Sovrapposizione Primo Strato" + +#: fdmprinter.json +#, fuzzy +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "Effettuare il primo e secondo strato di sovrapposizione oggetto nella direzione Z per compensare il filamento perso nel traferro. Tutti i modelli sopra il primo strato del modello saranno spostate verso il basso di questa quantità." diff --git a/resources/i18n/nl/fdmprinter.json.po b/resources/i18n/nl/fdmprinter.json.po index ff8f896a74..2c6e8a1df8 100644 --- a/resources/i18n/nl/fdmprinter.json.po +++ b/resources/i18n/nl/fdmprinter.json.po @@ -2414,3 +2414,16 @@ msgid "" "which in turn results in less upward connections with the next layer. Only " "applies to Wire Printing." msgstr "De afstand tussen de nozzle en horizontaal neergaande lijnen. Een grotere tussenruimte zorgt voor diagonaal neerwaarts gaande lijnen met een minder steile hoek. Hierdoor ontstaan minder opwaartse verbindingen met de volgende laag. Alleen van toepassing op Draadprinten." + +#: fdmprinter.json +msgctxt "layer_0_z_overlap label" +msgid "Initial Layer Z Overlap" +msgstr "Z Overlap Eerste Laag" + +#: fdmprinter.json +msgctxt "layer_0_z_overlap description" +msgid "" +"Make the first and second layer of the object overlap in the Z direction to " +"compensate for the filament lost in the airgap. All models above the first " +"model layer will be shifted down by this amount." +msgstr "Laat de eerste en tweede laag overlappen in de Z-richting om te compenseren voor verloren materiaal in de luchtlaag. Alle stukjes model boven de eerste laag worden met deze hoveelheid naar beneden verschoven." diff --git a/resources/machines/fdmprinter.json b/resources/machines/fdmprinter.json index c872437f7d..3890d4182e 100644 --- a/resources/machines/fdmprinter.json +++ b/resources/machines/fdmprinter.json @@ -1577,8 +1577,8 @@ "description": "Make the first and second layer of the object overlap in the Z direction to compensate for the filament lost in the airgap. All models above the first model layer will be shifted down by this amount.", "unit": "mm", "type": "float", - "default": 0.05, - "inherit_function": "layer_height / 2", + "default": 0.22, + "inherit_function": "raft_airgap / 2", "min_value": "0", "max_value_warning": "layer_height", "enabled": "adhesion_type == \"raft\"", @@ -1772,7 +1772,7 @@ "type": "float", "min_value": "0", "max_value": "100", - "default": 100, + "default": 0, "global_only": "True", "visible": false, "enabled": "adhesion_type == \"raft\"", @@ -1784,7 +1784,7 @@ "type": "float", "min_value": "0", "max_value": "100", - "default": 100, + "default": 0, "global_only": "True", "visible": false, "inherit": true, @@ -1797,7 +1797,7 @@ "type": "float", "min_value": "0", "max_value": "100", - "default": 100, + "default": 0, "global_only": "True", "visible": false, "inherit": true, @@ -1810,7 +1810,7 @@ "type": "float", "min_value": "0", "max_value": "100", - "default": 100, + "default": 0, "global_only": "True", "visible": false, "inherit": true,