# --------------------------------------------------------------------- # # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image # pour la SantÈ) # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton # Previous Authors : Laurent Guigues, Jean-Pierre Roux # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil # # This software is governed by the CeCILL-B license under French law and # abiding by the rules of distribution of free software. You can use, # modify and/ or redistribute the software under the terms of the CeCILL-B # license as circulated by CEA, CNRS and INRIA at the following URL # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html # or in the file LICENSE.txt. # # As a counterpart to the access to the source code and rights to copy, # modify and redistribute granted by the license, users are provided only # with a limited warranty and the software's author, the holder of the # economic rights, and the successive licensors have only limited # liability. # # The fact that you are presently reading this means that you have had # knowledge of the CeCILL-B license and that you accept its terms. # ------------------------------------------------------------------------ */ load std load wx load wxvtk define DoubleSlicer wxvtk description "Simple viewer displaying the same slice of two images. The slice is controlled by a slider. See exampleDoubleSlicer.bbs." author "laurent.guigues at creatis.insa-lyon.fr" new LayoutSplit main new LayoutLine slicers new Viewer2D slicer1 new Viewer2D slicer2 new Slider slider set main.Proportion 80 set slicers.Orientation HORIZONTAL connect slicers.Widget main.Widget1 connect slicer1.Widget slicers.Widget1 connect slicer2.Widget slicers.Widget2 connect slider.Widget main.Widget2 connect slider.Out slicer1.Slice connect slider.Out slicer2.Slice # WE NEED A MultipleInputs BOX TO CONNECT BOTH # slider.BoxChange AND THE INPUT BoxExecuteSlicer1 # OF THE COMPLEX BOX TO slicer1.BoxExecute # idem for slicer2 new MultipleInputs refresh1 new MultipleInputs refresh2 connect refresh1.Out slicer1.BoxExecute connect refresh2.Out slicer2.BoxExecute connect slider.BoxChange refresh2.In1 connect slider.BoxChange refresh1.In1 # set main.Proportion 80 set slider.Title "Slice" input In1 slicer1.In "Left (or top) image" input In2 slicer2.In "Right (or bottom) image" input WinDialog main.WinDialog "Execute in dialog mode" input WinTitle main.WinTitle "Title of the window" input WinWidth main.WinWidth "Width of the window" input WinHeight main.WinHeight "Width of the window" input Orientation slicers.Orientation "Orientation of the images (0=Horizontal / 1=Vertical)" input RefreshSlicer1 refresh1.In2 "Refreshes the first slicer" input RefreshSlicer2 refresh2.In2 "Refreshes the second slicer" input BoxProcessModeSlicer1 slicer1.BoxProcessMode "Process mode of the first slicer" input BoxProcessModeSlicer2 slicer2.BoxProcessMode "Process mode of the second slicer" output Widget main.Widget "Widget" # exec slicer1 exec main endefine