#---------------------------------------------------------------------
-new Slider slider
- set slider.Title "Slice"
+new Slider sliceSider
+ set sliceSider.Title "Slice"
#Slider size is the number of planes
- connect gveZ.Out slider.Max
+ connect gveZ.Out sliceSider.Max
#initial slice is the middle one
- connect div2.Out slider.In
- set slider.ChangeResolution 1
+ connect div2.Out sliceSider.In
+ set sliceSider.ChangeResolution 1
new Slider lowerThresholdSlider
set lowerThresholdSlider.Title "LowerThreshold"
set lowerThresholdSlider.Max 50
set lowerThresholdSlider.In 20
set lowerThresholdSlider.ChangeResolution 1
+
+new Slider lowerOpacitySlider
+ set lowerOpacitySlider.Title "LowerOpacity"
+ set lowerOpacitySlider.Max 100
+ set lowerOpacitySlider.In 20
+ set lowerOpacitySlider.Orientation V
new Slider upperThresholdSlider
set upperThresholdSlider.Title "UpperThreshold"
set upperThresholdSlider.In 500
set upperThresholdSlider.ChangeResolution 1
+new Slider upperOpacitySlider
+ set upperOpacitySlider.Title "UpperOpacity"
+ set upperOpacitySlider.Max 100
+ set upperOpacitySlider.In 100
+ set upperOpacitySlider.Orientation V
+
new Slider smoothSlider
set smoothSlider.Title "Smooth"
set smoothSlider.Max 10
new CommandButton refresh
set refresh.Label "Refresh"
- set refresh.In "exec isoextractorthreshold;exec isoextractorsmooth;exec mainSplit"
+ set refresh.In "exec isoextractorthreshold;exec isoextractorsmooth;exec viewer2DImageSegmented; exec viewer2DImageSmooth; exec viewer2DImageOriginal; exec mainSplit"
new MultipleInputs refreshimages
- //connect slider.BoxChange refreshimages.In1
+ connect sliceSider.BoxChange refreshimages.In1
connect upperThresholdSlider.BoxChange refreshimages.In2
connect lowerThresholdSlider.BoxChange refreshimages.In3
connect smoothSlider.BoxChange refreshimages.In4
new Viewer2D viewer2DImageOriginal
connect reader.Out viewer2DImageOriginal.In
- connect slider.Out viewer2DImageOriginal.Slice
- connect slider.BoxChange viewer2DImageOriginal.BoxExecute
+ connect sliceSider.Out viewer2DImageOriginal.Slice
+ connect sliceSider.BoxChange viewer2DImageOriginal.BoxExecute
#---------------------------------------------------------------------
new Viewer2D viewer2DImageSegmented
connect threshold.Out viewer2DImageSegmented.In
- connect slider.Out viewer2DImageSegmented.Slice
-// connect slider.BoxChange viewer2DImageSegmented.BoxExecute
+ connect sliceSider.Out viewer2DImageSegmented.Slice
+// connect sliceSider.BoxChange viewer2DImageSegmented.BoxExecute
connect refreshimages.Out viewer2DImageSegmented.BoxExecute
#---------------------------------------------------------------------
new Viewer2D viewer2DImageSmooth
connect smooth.Out viewer2DImageSmooth.In
- connect slider.Out viewer2DImageSmooth.Slice
- connect slider.BoxChange viewer2DImageSmooth.BoxExecute
+ connect sliceSider.Out viewer2DImageSmooth.Slice
+ connect sliceSider.BoxChange viewer2DImageSmooth.BoxExecute
#---------------------------------------------------------------------
new IsoSurfaceExtractor isoextractorthreshold
connect threshold.Out isoextractorthreshold.In
- set isoextractorthreshold.Opacity 1.0
- set isoextractorthreshold.Isovalue 100
+ set isoextractorthreshold.Opacity 1
+ #set isoextractorthreshold.Isovalue 10
+set isoextractorthreshold.Isovalue 100
connect colourUpper.Out isoextractorthreshold.Colour
connect viewernvImagethreshold3D.Renderer isoextractorthreshold.Renderer
# set viewernvImageSmooth3D.nTypeView "5"
//connect refreshimages.Out viewernvImageSmooth3D.BoxExecute
+new Div div3
+ connect lowerOpacitySlider.Out div3.In1
+ set div3.In2 100
+
new IsoSurfaceExtractor isoextractorsmooth
connect smooth.Out isoextractorsmooth.In
- set isoextractorsmooth.Opacity 0.2
+ connect div3.Out isoextractorsmooth.Opacity
set isoextractorsmooth.Isovalue 200
connect colourLower.Out isoextractorsmooth.Colour
connect viewernvImageSmooth3D.Renderer isoextractorsmooth.Renderer
connect sliderLayout.Widget toolLayout.Widget1
connect buttonLayout.Widget toolLayout.Widget2
+
+//new ImageWriter imw
+// connect smooth.Out imw.In
connect refresh.BoxChange smooth.BoxExecute
+new LayoutLine vSliderLayout
+ connect lowerOpacitySlider.Widget vSliderLayout.Widget1
+ connect upperOpacitySlider.Widget vSliderLayout.Widget2
+
+new LayoutSplit layout3D
+ set layout3D.Orientation H
+ set layout3D.Proportion 90
+ connect downLayout.Widget layout3D.Widget1
+ connect vSliderLayout.Widget layout3D.Widget2
+
#---------------------------------------------------------------------
new LayoutSplit splitUp
- set splitUp.Proportion 50
+ set splitUp.Proportion 38
connect toolLayout.Widget splitUp.Widget1
connect upLayout.Widget splitUp.Widget2
- connect slider.Widget sliderLayout.Widget1
+ connect sliceSider.Widget sliderLayout.Widget1
connect lowerThresholdSlider.Widget sliderLayout.Widget2
connect upperThresholdSlider.Widget sliderLayout.Widget3
connect smoothSlider.Widget sliderLayout.Widget4
new LayoutSplit mainSplit
- set mainSplit.Proportion 66
+ set mainSplit.Proportion 50
set mainSplit.WinHeight 1200
set mainSplit.WinWidth 1600
set mainSplit.WinTitle "Processing / Viewing example (demoFiltering1.bbs) "
connect splitUp.Widget mainSplit.Widget1
- connect downLayout.Widget mainSplit.Widget2
+ connect layout3D.Widget mainSplit.Widget2
#---------------------------------------------------------------------