self._idMap = {}
self._geometryList = []
r.ParseFile(open(filename, "r"))
+
+ self._scale = float(self._base['collada'][0]['asset'][0]['unit'][0]['_meter']) * 1000
for instance_visual_scene in self._base['collada'][0]['scene'][0]['instance_visual_scene']:
for node in self._idMap[instance_visual_scene['_url']]['node']:
startIndex = len(self.vertexes)
for idx in xrange(0, len(positionList)/3):
- x = positionList[idx*3]
- y = positionList[idx*3+1]
- z = positionList[idx*3+2]
+ x = positionList[idx*3] * self._scale
+ y = positionList[idx*3+1] * self._scale
+ z = positionList[idx*3+2] * self._scale
if matrix != None:
self.vertexes.append(Vector3(x * matrix[0] + y * matrix[1] + z * matrix[2] + matrix[3], x * matrix[4] + y * matrix[5] + z * matrix[6] + matrix[7], x * matrix[8] + y * matrix[9] + z * matrix[10] + matrix[11]))
else:
c = configBase.SettingRow(left, "Fill Density (%)", 'fill_density', '20', 'This controls how densily filled the insides of your print will be. For a solid part use 100%, for an empty part use 0%. A value around 20% is usually enough')
validators.validFloat(c, 0.0, 100.0)
- configBase.TitleRow(left, "Skirt")
- c = configBase.SettingRow(left, "Line count", 'skirt_line_count', '1', 'The skirt is a line drawn around the object at the first layer. This helps to prime your extruder, and to see if the object fits on your platform.\nSetting this to 0 will disable the skirt. Multiple skirt lines can help priming your extruder better for small objects.')
- validators.validInt(c, 0, 10)
- c = configBase.SettingRow(left, "Start distance (mm)", 'skirt_gap', '6.0', 'The distance between the skirt and the first layer.\nThis is the minimal distance, multiple skirt lines will be put outwards from this distance.')
- validators.validFloat(c, 0.0)
-
configBase.TitleRow(right, "Speed && Temperature")
c = configBase.SettingRow(right, "Print speed (mm/s)", 'print_speed', '50', 'Speed at which printing happens. A well adjusted Ultimaker can reach 150mm/s, but for good quality prints you want to print slower. Printing speed depends on a lot of factors. So you will be experimenting with optimal settings for this.')
validators.validFloat(c, 1.0)
validators.validInt(c, 10)
configBase.settingNotify(c, self.preview3d.updateCenterY)
+ configBase.TitleRow(left, "Skirt")
+ c = configBase.SettingRow(left, "Line count", 'skirt_line_count', '1', 'The skirt is a line drawn around the object at the first layer. This helps to prime your extruder, and to see if the object fits on your platform.\nSetting this to 0 will disable the skirt. Multiple skirt lines can help priming your extruder better for small objects.')
+ validators.validInt(c, 0, 10)
+ c = configBase.SettingRow(left, "Start distance (mm)", 'skirt_gap', '6.0', 'The distance between the skirt and the first layer.\nThis is the minimal distance, multiple skirt lines will be put outwards from this distance.')
+ validators.validFloat(c, 0.0)
+
configBase.TitleRow(left, "Retraction")
c = configBase.SettingRow(left, "Minimum travel (mm)", 'retraction_min_travel', '5.0', 'Minimum amount of travel needed for a retraction to happen at all. To make sure you do not get a lot of retractions in a small area')
validators.validFloat(c, 0.0)