- Timestamp:
- Feb 20, 2014 3:16:12 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/1.3/gui/scripts/vtkisosurfaceviewer.tcl
r3879 r4186 150 150 private variable _legendPending 0 151 151 private variable _field "" 152 private variable _colorMode " vmag"; # Mode of colormap (vmag or scalar)152 private variable _colorMode "scalar"; # Mode of colormap (vmag or scalar) 153 153 private variable _fieldNames {} 154 154 private variable _fields … … 235 235 cutplaneEdges 0 236 236 cutplaneLighting 1 237 cutplanePreinterp 0237 cutplanePreinterp 1 238 238 cutplaneOpacity 100 239 239 cutplaneVisible 0 … … 440 440 441 441 eval itk_initialize $args 442 443 EnableWaitDialog 500 442 444 Connect 443 445 update … … 772 774 if { $_reportClientInfo } { 773 775 # Tell the server the viewer, hub, user and session. 774 # Do this immediately on connect before buff ing any commands776 # Do this immediately on connect before buffering any commands 775 777 global env 776 778 … … 875 877 set _hardcopy($tag) $bytes 876 878 } 877 EventuallyRequestLegend878 879 } 879 880 … … 1507 1508 set font "Arial 8" 1508 1509 set lineht [font metrics $font -linespace] 1509 set c $itk_component(view)1510 1510 set w 12 1511 1511 set h [expr {$_height - 2 * ($lineht + 2)}] 1512 if { $h < 1 } {1512 if { $h < 1 } { 1513 1513 return 1514 1514 } … … 1698 1698 itk_component add numcontours { 1699 1699 Rappture::Spinint $inner.numcontours \ 1700 -min 1-max 50 -font "arial 9"1700 -min 0 -max 50 -font "arial 9" 1701 1701 } 1702 1702 $itk_component(numcontours) value $_settings(numContours) … … 1773 1773 "static_triad" "static" \ 1774 1774 "closest_triad" "closest" \ 1775 "furthest_triad" "f urthest" \1775 "furthest_triad" "farthest" \ 1776 1776 "outer_edges" "outer" 1777 1777 $itk_component(axisMode) value "static" … … 2116 2116 } 2117 2117 array set style [$dataobj style $comp] 2118 if { $dataobj != $_first } {2118 if { $dataobj != $_first || $style(-levels) == 1 } { 2119 2119 set style(-opacity) 1 2120 2120 } 2121 if { $_currentColormap == "" } {2122 set stylelist [$dataobj style $comp]2123 if { $stylelist != "" } {2124 array set style $stylelist2125 set stylelist [array get style]2126 SetCurrentColormap $stylelist2127 }2128 $itk_component(colormap) value $style(-color)2129 }2130 2121 SendCmd "cutplane add $tag" 2131 SendCmd "cutplane edges 0 $tag" 2132 SendCmd "cutplane wireframe 0 $tag" 2133 SendCmd "cutplane lighting 1 $tag" 2134 SendCmd "cutplane linewidth 1 $tag" 2135 2136 foreach axis { x y z } { 2137 SendCmd "cutplane slice $axis 0.5 $tag" 2138 SendCmd "cutplane axis $axis 0 $tag" 2139 } 2122 SendCmd "cutplane visible 0 $tag" 2123 2140 2124 # This is too complicated. We want to set the colormap, number of 2141 2125 # isolines and opacity for the dataset. They can be the default values, … … 2157 2141 } 2158 2142 if { $_currentColormap == "" } { 2143 SetCurrentColormap $style(-color) 2159 2144 $itk_component(colormap) value $style(-color) 2160 2145 } … … 2296 2281 "move" { 2297 2282 set axis [lindex $args 0] 2298 set a [string toupper $axis]2299 set oldval $_settings(cutplane${a}Position)2300 2283 set newval [lindex $args 1] 2301 2284 if {[llength $args] != 2} { … … 2505 2488 set _currentColormap $name 2506 2489 SendCmd "contour3d colormap $_currentColormap" 2490 SendCmd "cutplane colormap $_currentColormap" 2507 2491 } 2508 2492 … … 2546 2530 return 2547 2531 } 2532 if { $_currentNumContours < 1 } { 2533 set _contourList "" 2534 return 2535 } 2548 2536 foreach { vmin vmax } $_limits($_curFldName) break 2549 2537 set v [blt::vector create \#auto]
Note: See TracChangeset
for help on using the changeset viewer.