]> Creatis software - creaMaracasVisu.git/blob - bbtk/bbs/boxes/Mesh_tool_ApplyDeformation.bbs
9456a366918fa8947e75711d6f61e75f888decaa
[creaMaracasVisu.git] / bbtk / bbs / boxes / Mesh_tool_ApplyDeformation.bbs
1 # ----------------------------------
2 # - BBTKGEditor v 1.5 BBS BlackBox Script (Complex Box)
3 # - /home/garzon/Creatis/C23/creatools_source/creaMaracasVisu/bbtk/bbs/boxes/Mesh_tool_ApplyDeformation.bbs
4 # ----------------------------------
5
6 include std
7 include itkvtk
8 include wx
9 include vtk
10 include std
11 include creaMaracasVisu
12 include creaVtk
13 include itkvtk
14
15 define Mesh_tool_ApplyDeformation creaMaracasVisu
16
17 author "info-dev@creatis.insa-lyon.fr"
18 description "Show N Points"
19
20 category "demo"
21
22 new wx:LayoutLine Box08
23
24 new vtk:UpdateRender Box11
25   set Box11.Active "true"
26
27 new wx:LayoutLine Box79
28   set Box79.Orientation "H"
29   set Box79.WinTitle "New Surface ( Magenta )"
30
31 new std:MagicBox Box66
32
33 new std:MagicBox Box67
34
35 new vtk:vtkImageDataPointerRelay Box35
36
37 new creaMaracasVisu:PolyDataToActor_Widget Box37
38   set Box37.color "0 1 1"
39
40 new wx:LayoutTab Box40
41
42 new wx:CommandButton Box42
43   set Box42.Label "Apply  (Magenta->To Red)"
44
45 new wx:CommandButton Box43
46   set Box43.Label "Reset Tool"
47
48 new wx:LayoutLine Box44
49   set Box44.Orientation "V"
50   set Box44.WinTitle "1.1 Mesh Action"
51
52 new creaVtk:MeshManager_tool Box45
53   set Box45.Tool "32"
54
55 new std:MagicBox Box46
56
57 new std:MultipleInputs Box51
58
59 new std:MagicBox Box63
60
61 new std:MagicBox Box64
62
63 new std:MagicBox Box65
64
65 new std:MagicBox Box69
66
67 new std:MagicBox Box71
68
69 new creaMaracasVisu:MeshContours_Widget Box72
70   set Box72.colorMesh "0 1 1"
71
72 new wx:LayoutLine Box81
73   set Box81.WinTitle "Step 1.   Surface"
74
75 new wx:LayoutTab Box82
76
77 new creaMaracasVisu:wxVtkBaseView_Info Box96
78
79 new creaVtk:MeshManager_tool Box48
80   set Box48.Tool "35"
81
82 new creaVtk:MeshDeformation Box39
83   set Box39.TypeIn "1"
84
85 new wx:Slider Box49
86   set Box49.In "20"
87   set Box49.Label "true"
88   set Box49.Max "40"
89   set Box49.Min "1"
90   set Box49.ReactiveOnTrack "true"
91   set Box49.Title "Size Deformation"
92
93 new wx:CheckBox Box50
94   set Box50.Title "Active"
95
96 new creaVtk:PlaneWidget Box58
97   set Box58.ReactiveType "1"
98   set Box58.Representation "1"
99   set Box58.Resolution "5"
100
101 new std:MultipleInputs Box59
102
103 new wx:CommandButton Box53
104   set Box53.Label "-"
105
106 new wx:CommandButton Box54
107   set Box54.Label "+"
108
109 new wx:LayoutLine Box56
110   set Box56.Orientation "H"
111
112 new creaVtk:PlaneWidget_Base Box57
113   set Box57.Param "-1"
114   set Box57.Type "1"
115
116 new creaVtk:PlaneWidget_Base Box60
117   set Box60.Param "1"
118   set Box60.Type "1"
119
120 new std:MultipleInputs Box61
121
122 new creaVtk:MeshManager Box62
123   set Box62.MemoryMode "true"
124
125 new std:MultipleInputs Box73
126
127 new creaVtk:PointPickerNearest Box75
128   set Box75.Active "true"
129
130 new creaMaracasVisu:wxVtkBaseView_Info Box76
131   set Box76.InteractionType "6"
132
133 new std:MathOperationVector Box78
134   set Box78.Type "2"
135
136 new vtk:ImageVtkProperties Box83
137
138 new std:SharedMemory Box85
139
140 new std:SharedMemory Box86
141
142 new std:SharedMemory Box87
143
144 new std:MathOperationVector Box88
145   set Box88.Type "3"
146
147 new creaMaracasVisu:SetPosition Box89
148   set Box89.Active "false"
149
150 new creaMaracasVisu:wxVtkBaseView_info_tool Box90
151   set Box90.Type "1"
152
153 new creaMaracasVisu:wxVtkBaseView_info_tool Box91
154   set Box91.Type "0"
155
156 new creaVtk:PointPicker Box92
157   set Box92.TypeEvent "2"
158
159 new std:ConcatStrings_tool Box94
160   set Box94.Type "1"
161
162 new std:ConcatStrings Box95
163
164 new std:ConcatStrings_tool Box97
165   set Box97.Type "1"
166
167 new std:ConcatStrings Box98
168
169 new std:ConcatStrings_tool Box99
170   set Box99.Type "1"
171
172 new std:ConcatStrings_tool Box100
173   set Box100.Type "1"
174
175 new std:ConcatStrings_tool Box101
176   set Box101.Type "1"
177
178 new std:ConcatStrings Box102
179
180 new std:ConcatStrings_tool Box103
181   set Box103.Type "1"
182
183 new wx:RadioButton Box104
184   set Box104.In0 "Magenta"
185   set Box104.In1 "Colour"
186   set Box104.In2 "B&W"
187
188 new std:StringSelect Box105
189   set Box105.In0 "false"
190   set Box105.In1 "true"
191   set Box105.In2 "true"
192
193 new vtk:SurfaceTexture Box106
194
195 new std:Add Box107
196   set Box107.In2 "-1"
197
198 new wx:LayoutLine Box108
199   set Box108.Orientation "H"
200
201 new std:MultipleInputs Box109
202
203 new creaMaracasVisu:wxVtkBaseView_Info Box110
204
205 new std:GetVectorDoubleElement Box111
206   set Box111.I "0"
207
208 new std:GetVectorDoubleElement Box112
209   set Box112.I "1"
210
211 new creaMaracasVisu:wxVtkBaseView_Info Box113
212   set Box113.InteractionType "8"
213
214 new creaMaracasVisu:wxVtkBaseView_info_tool Box114
215   set Box114.Type "1"
216
217 new std:MathOperationVector Box115
218   set Box115.Type "2"
219
220 new std:ConcatStrings_tool Box116
221   set Box116.Type "1"
222
223 new std:ConcatStrings Box117
224   set Box117.In1 "true"
225
226 new std:Mul Box118
227
228 new std:ReplaceCleanString Box119
229   set Box119.Replace "1"
230   set Box119.Search "true"
231
232 new creaVtk:MeshManager_tool Box121
233   set Box121.Tool "35"
234
235 new itkvtk:GeodesicMeshDeformation Box122
236   set Box122.TypeIn "1"
237
238 new wx:CheckBox_tool Box123
239   set Box123.In "false"
240
241 new wx:LayoutLine Box124
242   set Box124.Orientation "V"
243   set Box124.WinTitle "1.2 Apply Changes"
244
245 new wx:LayoutLine Box125
246   set Box125.Orientation "V"
247   set Box125.WinTitle "Visu"
248
249 new wx:LayoutTab Box126
250
251 new wx:LayoutLine Box127
252   set Box127.Orientation "V"
253   set Box127.WinTitle "conf"
254
255 new wx:LayoutTab Box128
256
257 new wx:OutputText Box129
258
259 new wx:OutputText Box130
260
261 new wx:CommandButton Box131
262   set Box131.Label "Undo"
263
264 new wx:CommandButton Box132
265   set Box132.Label "Redo"
266
267 new wx:LayoutLine Box133
268   set Box133.Orientation "H"
269
270 new creaVtk:MeshManager_tool Box134
271   set Box134.BoxProcessMode "Manual"
272   set Box134.Tool "37"
273
274 new creaVtk:MeshManager_tool Box137
275   set Box137.BoxProcessMode "Manual"
276   set Box137.Tool "10"
277
278 new creaVtk:MeshManager_tool Box138
279   set Box138.BoxProcessMode "Manual"
280   set Box138.Tool "20"
281
282 new creaMaracasVisu:SetPosition Box142
283
284 new creaMaracasVisu:SetPosition Box143
285
286 new std:MathOperationVector Box144
287   set Box144.Type "3"
288
289 new std:MathOperationVector Box145
290   set Box145.Type "3"
291
292 new creaVtk:PlaneWidget_Base Box154
293   set Box154.Type "3"
294
295 new creaVtk:PlaneWidget_Base Box151
296   set Box151.Type "3"
297
298 new std:GetVectorDoubleSubVector Box150
299   set Box150.ErrorValue "0"
300   set Box150.I "0"
301   set Box150.Size "3"
302
303 new std:GetVectorDoubleSubVector Box152
304   set Box152.ErrorValue "0"
305   set Box152.I "3"
306   set Box152.Size "3"
307
308 new creaVtk:PlaneWidget_Base Box153
309   set Box153.Type "2"
310
311 new std:GetVectorDoubleSubVector Box155
312   set Box155.ErrorValue "0"
313   set Box155.I "0"
314   set Box155.Size "3"
315
316 new std:GetVectorDoubleSubVector Box156
317   set Box156.ErrorValue "0"
318   set Box156.I "3"
319   set Box156.Size "3"
320
321 new creaVtk:PlaneWidget_Base Box158
322   set Box158.Type "2"
323
324 new std:ConcatStrings_tool Box159
325   set Box159.BoxProcessMode "Manual"
326   set Box159.In1 "-1"
327   set Box159.Type "1"
328
329 new std:MultipleInputs Box160
330
331
332 connect Box66.Out Box11.Renderer
333 connect Box66.Out Box37.render
334 connect Box79.Widget Box40.Widget2
335 connect Box46.Out Box45.MeshManagerModel
336 connect Box45.BoxChange Box51.In2
337 connect Box71.Out Box72._wxvtkbaseview3D1
338 connect Box64.Out Box72._wxvtkbaseview2D1
339 connect Box65.Out Box72._wxvtkbaseview2D2
340 connect Box69.Out Box72._wxvtkbaseview2D3
341 connect Box81.Widget Box08.Widget2
342 connect Box96.vtkRenderer Box66.In
343 connect Box40.Widget Box81.Widget2
344 connect Box37.boxchange Box11.BoxExecute
345 connect Box50.Out Box58.Active
346 connect Box50.BoxChange Box59.In2
347 connect Box59.BoxChange Box58.BoxExecute
348 connect Box96.vtkRenderer Box58.Renderer
349 connect Box35.Out Box58.In
350 connect Box53.Widget Box56.Widget2
351 connect Box54.Widget Box56.Widget4
352 connect Box58.Base Box57.In
353 connect Box58.Base Box60.In
354 connect Box53.BoxChange Box57.BoxExecute
355 connect Box54.BoxChange Box60.BoxExecute
356 connect Box49.BoxChange Box61.In1
357 connect Box67.Out Box62.Mesh
358 connect Box62.MeshManagerModel Box48.MeshManagerModel
359 connect Box50.Out Box37.active
360 connect Box42.BoxChange Box51.BoxExecute
361 connect Box43.BoxChange Box48.BoxExecute
362 connect Box67.Out Box48.Mesh
363 connect Box63.BoxChange Box73.In3
364 connect Box73.BoxChange Box72._execute
365 connect Box76.Point Box78.In0
366 connect Box35.Out Box83.In
367 connect Box83.Spacing Box78.In1
368 connect Box78.Out Box75.Point
369 connect Box58.Center Box88.In0
370 connect Box83.Spacing Box88.In1
371 connect Box88.Out Box89.Point
372 connect Box76.InteractorwxVtkBaseView_model Box90.InteractorwxVtkBaseView_model
373 connect Box76.InteractorwxVtkBaseView_model2 Box90.InteractorwxVtkBaseView_model2
374 connect Box64.Out Box90.wxVtkBaseView
375 connect Box65.Out Box90.wxVtkBaseView2
376 connect Box69.Out Box90.wxVtkBaseView3
377 connect Box76.InteractorwxVtkBaseView_model3 Box90.InteractorwxVtkBaseView_model3
378 connect Box96.Box_wxVtkBaseView_Info Box91.Box_wxVtkBaseView_Info
379 connect Box71.Out Box91.wxVtkBaseView
380 connect Box50.BoxChange Box91.BoxExecute
381 connect Box50.BoxChange Box90.BoxExecute
382 connect Box75.PointId Box87.In
383 connect Box75.Normal Box86.In
384 connect Box75.PointOut Box85.In
385 connect Box96.wxVtkBaseView Box89.wxVtkBaseView
386 connect Box96.vtkRenderer Box92.Renderer
387 connect Box92.Point Box85.In1
388 connect Box92.PointId Box87.In1
389 connect Box92.Normal Box86.In1
390 connect Box75.PointOut Box94.In1
391 connect Box95.Box_ConcatStrings Box94.Box_ConcatString
392 connect Box98.Box_ConcatStrings Box97.Box_ConcatString
393 connect Box92.Normal Box97.In1
394 connect Box95.Box_ConcatStrings Box99.Box_ConcatString
395 connect Box92.Point Box99.In1
396 connect Box98.Box_ConcatStrings Box100.Box_ConcatString
397 connect Box75.Normal Box100.In1
398 connect Box102.Box_ConcatStrings Box101.Box_ConcatString
399 connect Box102.Box_ConcatStrings Box103.Box_ConcatString
400 connect Box75.PointId Box101.In1
401 connect Box92.PointId Box103.In1
402 connect Box98.Out Box58.NormalIn
403 connect Box76.BoxChange Box101.BoxExecute
404 connect Box92.BoxChange Box103.BoxExecute
405 connect Box103.BoxChange Box99.BoxExecute
406 connect Box99.BoxChange Box97.BoxExecute
407 connect Box101.BoxChange Box94.BoxExecute
408 connect Box94.BoxChange Box100.BoxExecute
409 connect Box104.Out Box105.In
410 connect Box105.Out Box37.scalarvisibility
411 connect Box104.Out Box107.In1
412 connect Box107.Out Box106.ColorType
413 connect Box50.Widget Box108.Widget2
414 connect Box104.Widget Box108.Widget4
415 connect Box35.Out Box106.Image
416 connect Box104.BoxChange Box109.In1
417 connect Box110.BoxChange Box106.BoxExecute
418 connect Box109.BoxChange Box110.BoxExecute
419 connect Box71.Out Box110.wxVtkBaseView
420 connect Box110.WindowColorLevel Box111.In
421 connect Box110.WindowColorLevel Box112.In
422 connect Box112.Out Box106.ColorLevel
423 connect Box111.Out Box106.ColorWindow
424 connect Box63.BoxChange Box109.In2
425 connect Box113.InteractorwxVtkBaseView_model Box114.InteractorwxVtkBaseView_model
426 connect Box113.InteractorwxVtkBaseView_model2 Box114.InteractorwxVtkBaseView_model2
427 connect Box113.InteractorwxVtkBaseView_model3 Box114.InteractorwxVtkBaseView_model3
428 connect Box83.Spacing Box115.In1
429 connect Box113.Point Box115.In0
430 connect Box95.Box_ConcatStrings Box116.Box_ConcatString
431 connect Box115.Out Box116.In1
432 connect Box113.BoxChange Box116.BoxExecute
433 connect Box50.BoxChange Box114.BoxExecute
434 connect Box64.Out Box114.wxVtkBaseView
435 connect Box65.Out Box114.wxVtkBaseView2
436 connect Box69.Out Box114.wxVtkBaseView3
437 connect Box117.Out Box119.In
438 connect Box119.Out Box118.In1
439 connect Box50.Out Box118.In2
440 connect Box37.vtkprop3D Box92.Prop3D
441 connect Box97.BoxChange Box59.In3
442 connect Box56.Widget Box44.Widget4
443 connect Box49.Widget Box44.Widget3
444 connect Box108.Widget Box44.Widget2
445 connect Box43.Widget Box44.Widget1
446 connect Box67.Out Box121.Mesh
447 connect Box62.MeshManagerModel Box121.MeshManagerModel
448 connect Box61.BoxChange Box122.BoxExecute
449 connect Box122.BoxChange Box73.In2
450 connect Box49.Out Box122.S
451 connect Box58.Center Box122.Center
452 connect Box102.Out Box122.EdgeId
453 connect Box118.Out Box122.Active
454 connect Box50.BoxChange Box61.In3
455 connect Box50.Widget Box123.CheckBoxWidget
456 connect Box42.BoxChange Box123.BoxExecute
457 connect Box124.Widget Box82.Widget4
458 connect Box42.Widget Box124.Widget2
459 connect Box67.BoxChange Box121.BoxExecute
460 connect Box62.MeshBase Box45.Mesh
461 connect Box62.MeshBase Box72._polydata
462 connect Box62.MeshBase Box37.polydata
463 connect Box62.MeshBase Box75.Mesh
464 connect Box62.MeshBase Box106.Mesh
465 connect Box62.MeshBase Box122.In
466 connect Box44.Widget Box126.Widget2
467 connect Box126.Widget Box79.Widget2
468 connect Box82.Widget Box79.Widget4
469 connect Box37.widgetB Box127.Widget2
470 connect Box72._widgetB Box127.Widget4
471 connect Box72._widgetA Box125.Widget2
472 connect Box37.widgetA Box125.Widget4
473 connect Box128.Widget Box79.Widget6
474 connect Box125.Widget Box128.Widget2
475 connect Box127.Widget Box128.Widget4
476 connect Box129.Widget Box125.Widget9
477 connect Box130.Widget Box127.Widget9
478 connect Box131.Widget Box133.Widget2
479 connect Box132.Widget Box133.Widget4
480 connect Box133.Widget Box44.Widget5
481 connect Box62.MeshManagerModel Box134.MeshManagerModel
482 connect Box122.BoxChange Box134.BoxExecute
483 connect Box131.BoxChange Box137.BoxExecute
484 connect Box132.BoxChange Box138.BoxExecute
485 connect Box62.MeshManagerModel Box138.MeshManagerModel
486 connect Box62.MeshManagerModel Box137.MeshManagerModel
487 connect Box50.Out Box89.Active
488 connect Box95.Out Box58.Origin
489 connect Box58.BoxChange Box61.In2
490 connect Box58.BoxChange Box89.BoxExecute
491 connect Box122.Out Box134.DoubleParams
492 connect Box96.wxVtkBaseView Box142.wxVtkBaseView
493 connect Box83.Spacing Box144.In1
494 connect Box83.Spacing Box145.In1
495 connect Box145.Out Box142.Point
496 connect Box96.wxVtkBaseView Box143.wxVtkBaseView
497 connect Box137.BoxChange Box142.BoxExecute
498 connect Box138.BoxChange Box143.BoxExecute
499 connect Box58.Base Box151.In
500 connect Box58.Base Box154.In
501 connect Box142.BoxChange Box154.BoxExecute
502 connect Box143.BoxChange Box151.BoxExecute
503 connect Box144.Out Box143.Point
504 connect Box137.Out Box150.In
505 connect Box150.Out Box145.In0
506 connect Box150.Out Box154.ParamVector
507 connect Box137.Out Box152.In
508 connect Box142.BoxChange Box153.BoxExecute
509 connect Box58.Base Box153.In
510 connect Box138.Out Box155.In
511 connect Box155.Out Box144.In0
512 connect Box138.Out Box156.In
513 connect Box155.Out Box151.ParamVector
514 connect Box156.Out Box158.ParamVector
515 connect Box143.BoxChange Box158.BoxExecute
516 connect Box58.Base Box158.In
517 connect Box152.Out Box153.ParamVector
518 connect Box58.Normal Box122.Direction
519 connect Box102.Box_ConcatStrings Box159.Box_ConcatString
520 connect Box160.BoxChange Box159.BoxExecute
521 connect Box131.BoxChange Box160.In1
522 connect Box132.BoxChange Box160.In2
523
524 # Complex input ports
525 input mesh Box67.In " "
526 input image Box35.In " "
527 input title Box08.WinTitle " "
528 input meshmanagermodel Box46.In " "
529 input boxChange Box63.In " "
530 input wxvtkbaseview2 Box64.In " "
531 input wxvtkbaseview3 Box65.In " "
532 input wxvtkbaseview4 Box69.In " "
533 input wxvtkbaseview1 Box71.In " "
534
535 # Complex output ports
536 output widget Box08.Widget " "
537 output ExportIsActive_concatstring_tool Box117.Box_ConcatStrings " "
538
539
540 endefine