Commit 11dc8fd7ecbeaa3ba52e93e43d0129457bc689b5
1 parent
1b2d6034
Exists in
smoothing_bin
Giving the user the option to choose the n steps to whitaker alg
Showing
2 changed files
with
9 additions
and
1 deletions
Show diff stats
invesalius/data/surface.py
invesalius/gui/dialogs.py
... | ... | @@ -1304,6 +1304,12 @@ class SurfaceMethodPanel(wx.Panel): |
1304 | 1304 | def _set_cb_types(self, evt): |
1305 | 1305 | if self.alg_types[evt.GetString()] == 'ca_smoothing': |
1306 | 1306 | self.ca_options.Enable() |
1307 | + elif self.alg_types[evt.GetString()] == 'Whitaker': | |
1308 | + self.ca_options.Enable() | |
1309 | + self.ca_options.angle.Disable() | |
1310 | + self.ca_options.max_distance.Disable() | |
1311 | + self.ca_options.min_weight.Disable() | |
1312 | + self.ca_options.steps.Enable() | |
1307 | 1313 | else: |
1308 | 1314 | self.ca_options.Disable() |
1309 | 1315 | evt.Skip() |
... | ... | @@ -1320,6 +1326,8 @@ class SurfaceMethodPanel(wx.Panel): |
1320 | 1326 | 'max distance': self.ca_options.max_distance.GetValue(), |
1321 | 1327 | 'min weight': self.ca_options.min_weight.GetValue(), |
1322 | 1328 | 'steps': self.ca_options.steps.GetValue()} |
1329 | + elif self.GetAlgorithmSelected() == 'Whitaker': | |
1330 | + options = {'steps': self.ca_options.steps.GetValue()} | |
1323 | 1331 | else: |
1324 | 1332 | options = {} |
1325 | 1333 | return options | ... | ... |