]> Creatis software - creaRigidRegistration.git/blob - PackRecalage/bbs/appli/ExampleReSlice3D.bbs
Feature #1766 Add licence terms for all files.
[creaRigidRegistration.git] / PackRecalage / bbs / appli / ExampleReSlice3D.bbs
1 # ---------------------------------------------------------------------
2 #
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image 
4 #                        pour la Santé)
5 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6 #
7 #  This software is governed by the CeCILL-B license under French law and 
8 #  abiding by the rules of distribution of free software. You can  use, 
9 #  modify and/ or redistribute the software under the terms of the CeCILL-B 
10 #  license as circulated by CEA, CNRS and INRIA at the following URL 
11 #  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html 
12 #  or in the file LICENSE.txt.
13 #
14 #  As a counterpart to the access to the source code and  rights to copy,
15 #  modify and redistribute granted by the license, users are provided only
16 #  with a limited warranty  and the software's author,  the holder of the
17 #  economic rights,  and the successive licensors  have only  limited
18 #  liability. 
19 #
20 #  The fact that you are presently reading this means that you have had
21 #  knowledge of the CeCILL-B license and that you accept its terms.
22 # ------------------------------------------------------------------------   
23
24 # ----------------------------------
25 # - BBTKGEditor v 1.2 BBS BlackBox Script
26 # - /Users/davila/Creatis/All5/creatools_source/creaRigidRegistration/PackRecalage/bbs/appli/ExampleReSlice3D.bbs
27 # ----------------------------------
28
29 # BBTK GEditor Script
30 # ----------------------
31
32 include std
33 include itkvtk
34 include creaMaracasVisu
35 include wx
36 include PackRecalage
37 include std
38 include vtk
39 include creaImageIO
40 include toolsbbtk
41
42 author "info-dev@creatis.insa-lyon.fr"
43 description "Recalage3D 1-point"
44 category "example"
45
46 new ViewerNV viewer2
47   set viewer2.nTypeView "5"
48
49 new Slider sdrAngleX
50   set sdrAngleX.In "0"
51   set sdrAngleX.Max "180"
52   set sdrAngleX.Min "-180"
53   set sdrAngleX.ReactiveOnTrack "true"
54   set sdrAngleX.Title "Rotation angle in X Axis"
55
56 new Slider sdrAngleY
57   set sdrAngleY.In "0"
58   set sdrAngleY.Max "180"
59   set sdrAngleY.Min "-180"
60   set sdrAngleY.ReactiveOnTrack "true"
61   set sdrAngleY.Title "Rotation angle in Y Axis"
62
63 new Slider sdrAngleZ
64   set sdrAngleZ.In "0"
65   set sdrAngleZ.Max "180"
66   set sdrAngleZ.Min "-180"
67   set sdrAngleZ.ReactiveOnTrack "true"
68   set sdrAngleZ.Title "Rotation angle in Z Axis"
69
70 new Slider sdrScaleX
71   set sdrScaleX.In "100"
72   set sdrScaleX.Max "300"
73   set sdrScaleX.Min "10"
74   set sdrScaleX.ReactiveOnTrack "true"
75   set sdrScaleX.Title "Scale in X Axis"
76
77 new Slider sdrScaleY
78   set sdrScaleY.In "100"
79   set sdrScaleY.Max "300"
80   set sdrScaleY.Min "10"
81   set sdrScaleY.ReactiveOnTrack "true"
82   set sdrScaleY.Title "Scale in Y Axis"
83
84 new Slider sdrScaleZ
85   set sdrScaleZ.In "100"
86   set sdrScaleZ.Max "300"
87   set sdrScaleZ.Min "10"
88   set sdrScaleZ.ReactiveOnTrack "true"
89   set sdrScaleZ.Title "Scale in Z Axis"
90
91 new Transform3D1PointBox transform
92
93 new ReSlicerBox reslicer
94   set reslicer.Interpolate true
95
96 new MultipleInputs mult
97
98 new MultipleInputs mult2
99
100 new MultipleInputs mult3
101
102 new ViewerNV viewerResult
103   set viewerResult.nTypeView "5"
104
105 new LayoutLine toolsLayout
106   set toolsLayout.Orientation "v"
107   set toolsLayout.WinTitle "Rotation"
108
109 new LayoutSplit resultLayout
110   set resultLayout.Orientation "v"
111   set resultLayout.Proportion "70"
112
113 new LayoutSplit main
114   set main.Orientation "h"
115   set main.Proportion "50"
116
117 new vtkImageDataPointerRelay Box22
118
119 new ImagesChooserDialogBox Box24
120
121 new ImageVtkProperties Box26
122
123 new VectorRescaleSlope Box27
124   set Box27.A 0.5
125   set Box27.B 0
126   set Box27.Type 0
127
128 new ConcatStrings Box28
129
130 new ConcatStrings Box29
131
132 new LayoutTab Box30
133
134 new SaveMHD-Button Box31
135
136 new LayoutLine Box32
137   set Box32.WinTitle "Scale"
138
139 new LayoutLine Box33
140   set Box33.WinTitle "Save"
141
142 new LayoutCenter Box34
143
144
145 connect viewer2.Point transform.CenterPoint
146 connect sdrAngleX.Out transform.AngleX
147 connect sdrAngleY.Out transform.AngleY
148 connect sdrAngleZ.Out transform.AngleZ
149 connect sdrScaleX.Out transform.ScaleX
150 connect sdrScaleY.Out transform.ScaleY
151 connect sdrScaleZ.Out transform.ScaleZ
152 connect transform.Out reslicer.Transform
153 connect viewer2.BoxChange mult.In2
154 connect sdrAngleX.BoxChange mult.In3
155 connect sdrAngleY.BoxChange mult.In4
156 connect sdrAngleZ.BoxChange mult.In5
157 connect sdrScaleX.BoxChange mult2.In1
158 connect sdrScaleY.BoxChange mult2.In2
159 connect sdrScaleZ.BoxChange mult2.In3
160 connect mult.BoxChange mult3.In1
161 connect mult2.BoxChange mult3.In2
162 connect mult3.BoxChange transform.BoxExecute
163 connect mult3.BoxChange reslicer.BoxExecute
164 connect reslicer.Out viewerResult.In
165 connect mult3.BoxChange viewerResult.BoxExecute
166 connect sdrAngleX.Widget toolsLayout.Widget1
167 connect sdrAngleY.Widget toolsLayout.Widget2
168 connect sdrAngleZ.Widget toolsLayout.Widget3
169 connect Box22.Out viewer2.In
170 connect Box22.Out reslicer.In
171 connect Box24.Out Box22.In
172 connect Box22.Out Box26.In
173 connect Box26.Size Box28.In1
174 connect Box28.Out Box27.In
175 connect Box27.Out Box29.In1
176 connect Box29.Out reslicer.Origin
177 connect viewer2.Widget main.Widget1
178 connect sdrScaleX.Widget Box32.Widget1
179 connect sdrScaleY.Widget Box32.Widget2
180 connect sdrScaleZ.Widget Box32.Widget3
181 connect Box32.Widget Box30.Widget2
182 connect Box33.Widget Box30.Widget3
183 connect toolsLayout.Widget Box30.Widget1
184 connect Box30.Widget resultLayout.Widget2
185 connect reslicer.Out Box31.In
186 connect Box31.Widget Box34.Widget2
187 connect Box34.Widget Box33.Widget1
188 connect viewerResult.Widget main.Widget2
189 connect main.Widget resultLayout.Widget1
190
191 exec resultLayout