From c799d5d1b99e2409886b9df695b8a803bef271f8 Mon Sep 17 00:00:00 2001 From: paulojamorim Date: Fri, 31 Jul 2009 11:34:41 +0000 Subject: [PATCH] FIX: fixed bug initial threshold from editor pencil --- invesalius/control.py | 7 +++++++ 1 file changed, 7 insertions(+), 0 deletions(-) diff --git a/invesalius/control.py b/invesalius/control.py index cf208c3..abff53f 100755 --- a/invesalius/control.py +++ b/invesalius/control.py @@ -18,6 +18,7 @@ class Controller(): self.volume = volume.Volume() self.__bind_events() + def __bind_events(self): ps.Publisher().subscribe(self.ImportDirectory, 'Import directory') ps.Publisher().subscribe(self.StartImportPanel, "Load data to import panel") @@ -63,6 +64,10 @@ class Controller(): proj.SetAcquisitionModality(acquisition_modality) proj.imagedata = imagedata + threshold_range = proj.imagedata.GetScalarRange() + const.THRESHOLD_OUTVALUE = threshold_range[0] + const.THRESHOLD_INVALUE = threshold_range[1] + # Based on imagedata, load data to GUI ps.Publisher().sendMessage('Load slice to viewer', (imagedata)) @@ -85,3 +90,5 @@ class Controller(): (min_thresh, max_thresh) = proj.threshold_modes.get_value(key) + + -- libgit2 0.21.2