Commit d5fab5769815c378b682185436184bb8139ea5a6
1 parent
64c3035a
Exists in
master
FIX: create prev_error and final_error as none
-report error if m_icp exist
Showing
2 changed files
with
3 additions
and
1 deletions
Show diff stats
invesalius/gui/dialogs.py
... | ... | @@ -3540,6 +3540,8 @@ class ICPCorregistrationDialog(wx.Dialog): |
3540 | 3540 | self.polydata = None |
3541 | 3541 | self.m_icp = None |
3542 | 3542 | self.initial_focus = None |
3543 | + self.prev_error = None | |
3544 | + self.final_error = None | |
3543 | 3545 | self.icp_mode = 0 |
3544 | 3546 | self.staticballs = [] |
3545 | 3547 | self.point_coord = [] | ... | ... |
invesalius/gui/task_navigator.py
... | ... | @@ -703,7 +703,6 @@ class NeuronavigationPanel(wx.Panel): |
703 | 703 | dialog = dlg.ICPCorregistrationDialog(nav_prop=(self.tracker_id, self.trk_init, self.ref_mode_id)) |
704 | 704 | if dialog.ShowModal() == wx.ID_OK: |
705 | 705 | self.m_icp, point_coord, transformed_points, prev_error, final_error = dialog.GetValue() |
706 | - dlg.ReportICPerror(prev_error, final_error) | |
707 | 706 | #TODO: checkbox in the dialog to transfer the icp points to 3D viewer |
708 | 707 | #create markers |
709 | 708 | # for i in range(len(point_coord)): |
... | ... | @@ -712,6 +711,7 @@ class NeuronavigationPanel(wx.Panel): |
712 | 711 | # Publisher.sendMessage('Create marker', coord=img_coord, marker_id=None, colour=(1,0,0)) |
713 | 712 | # Publisher.sendMessage('Create marker', coord=transf_coord, marker_id=None, colour=(0,0,1)) |
714 | 713 | if self.m_icp is not None: |
714 | + dlg.ReportICPerror(prev_error, final_error) | |
715 | 715 | self.checkicp.Enable(True) |
716 | 716 | self.checkicp.SetValue(True) |
717 | 717 | self.icp = True | ... | ... |