Commit 914780e9d02918e506cdc49368354934c5f0fdd2
1 parent
dc3c7ce0
Exists in
master
and in
3 other branches
Created default values to the projections
Showing
3 changed files
with
11 additions
and
5 deletions
Show diff stats
invesalius/constants.py
invesalius/data/slice_.py
invesalius/data/viewer_slice.py
... | ... | @@ -60,13 +60,15 @@ ORIENTATIONS = { |
60 | 60 | class ContourMIPConfig(wx.Panel): |
61 | 61 | def __init__(self, prnt, orientation): |
62 | 62 | wx.Panel.__init__(self, prnt) |
63 | - self.mip_size_spin = wx.SpinCtrl(self, -1, min=1, max=240, initial=1) | |
63 | + self.mip_size_spin = wx.SpinCtrl(self, -1, min=1, max=240, | |
64 | + initial=const.PROJECTION_MIP_SIZE) | |
64 | 65 | w, h = self.mip_size_spin.GetTextExtent('M') |
65 | 66 | self.mip_size_spin.SetMinSize((4 * w + 10, -1)) |
66 | 67 | self.mip_size_spin.SetMaxSize((4 * w + 10, -1)) |
67 | 68 | self.border_spin = FS.FloatSpin(self, -1, min_val=0, max_val=10, |
68 | - increment=0.1, value=0.1, digits=1, | |
69 | - agwStyle=FS.FS_LEFT) | |
69 | + increment=0.1, | |
70 | + value=const.PROJECTION_BORDER_SIZE, | |
71 | + digits=1, agwStyle=FS.FS_LEFT) | |
70 | 72 | w, h = self.border_spin.GetTextExtent('M') |
71 | 73 | self.border_spin.SetMinSize((5 * w + 10, -1)) |
72 | 74 | self.border_spin.SetMaxSize((5 * w + 10, -1)) |
... | ... | @@ -142,7 +144,7 @@ class Viewer(wx.Panel): |
142 | 144 | self.left_pressed = 0 |
143 | 145 | self.right_pressed = 0 |
144 | 146 | |
145 | - self._number_slices = 10 | |
147 | + self._number_slices = const.PROJECTION_MIP_SIZE | |
146 | 148 | self._mip_inverted = False |
147 | 149 | |
148 | 150 | self.spined_image = False #Use to control to spin | ... | ... |