mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
fix litho thickness computation
This commit is contained in:
parent
3e0b756a6d
commit
236b7574c0
2 changed files with 3 additions and 3 deletions
|
@ -108,7 +108,7 @@ class ImageReader(MeshReader):
|
|||
|
||||
Job.yieldThread()
|
||||
|
||||
if not lighter_is_higher:
|
||||
if lighter_is_higher is use_transparency_model:
|
||||
height_data = 1 - height_data
|
||||
|
||||
for _ in range(0, blur_iterations):
|
||||
|
@ -133,7 +133,7 @@ class ImageReader(MeshReader):
|
|||
min_luminance = 2.0 ** ((peak_height - base_height) / p)
|
||||
for (y, x) in numpy.ndindex(height_data.shape):
|
||||
mapped_luminance = min_luminance + (1.0 - min_luminance) * height_data[y, x]
|
||||
height_data[y, x] = peak_height - p * math.log(mapped_luminance, 2)
|
||||
height_data[y, x] = base_height + p * math.log(mapped_luminance, 2)
|
||||
else:
|
||||
height_data *= scale_vector.y
|
||||
height_data += base_height
|
||||
|
|
|
@ -35,7 +35,7 @@ class ImageReaderUI(QObject):
|
|||
self.smoothing = 1
|
||||
self.lighter_is_higher = False;
|
||||
self.use_transparency_model = True;
|
||||
self.transmittance_1mm = 40.0;
|
||||
self.transmittance_1mm = 20.0; # based on pearl PLA
|
||||
|
||||
self._ui_lock = threading.Lock()
|
||||
self._cancelled = False
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue