second clipping plane

This commit is contained in:
Joachim Schoeberl 2013-02-03 14:44:27 +00:00
parent d0629955db
commit 480661cfdd
3 changed files with 12 additions and 5 deletions

View File

@ -1164,6 +1164,13 @@ proc clippingdialog { } {
-command { clipplanecommand }
# -command { popupcheckredraw2 clippingdialog_pop4 ${viewoptions.clipping.enable} }
label $w.lab5 -text "Additional Distance"
scale $w.scale5 -orient horizontal -length 300 -from -1 -to 1.001 \
-resolution 0.0001 -tickinterval 0.5 \
-variable viewoptions.clipping.dist2 \
-command { clipplanecommand }
tixControl $w.clipdomain -label "Clip only domain" -integer true \
-variable viewoptions.clipping.onlydomain -min 0 -max 50 \
@ -1176,7 +1183,7 @@ proc clippingdialog { } {
-command { clipplanecommand; }
# -command { Ng_SetVisParameters; redraw }
pack $w.lab1 $w.scale1 $w.lab2 $w.scale2 $w.lab3 $w.scale3 $w.lab4 $w.scale4 $w.clipdomain $w.donotclipdomain
pack $w.lab1 $w.scale1 $w.lab2 $w.scale2 $w.lab3 $w.scale3 $w.lab4 $w.scale4 $w.lab5 $w.scale5 $w.clipdomain $w.donotclipdomain
checkbutton $w.cb1 -text "Enable clipping" \

View File

@ -2865,6 +2865,7 @@ void PlayAnimFile(const char* name, int speed, int maxcnt)
hclip.normal.Y() = atof (Tcl_GetVar (interp, "::viewoptions.clipping.ny", TCL_GLOBAL_ONLY));
hclip.normal.Z() = atof (Tcl_GetVar (interp, "::viewoptions.clipping.nz", TCL_GLOBAL_ONLY));
hclip.dist = atof (Tcl_GetVar (interp, "::viewoptions.clipping.dist", TCL_GLOBAL_ONLY));
hclip.dist2 = atof (Tcl_GetVar (interp, "::viewoptions.clipping.dist2", TCL_GLOBAL_ONLY));
hclip.enable = atoi (Tcl_GetVar (interp, "::viewoptions.clipping.enable", TCL_GLOBAL_ONLY));
vispar.clipdomain =
atoi (Tcl_GetVar (interp, "::viewoptions.clipping.onlydomain", TCL_GLOBAL_ONLY));
@ -2872,10 +2873,8 @@ void PlayAnimFile(const char* name, int speed, int maxcnt)
atoi (Tcl_GetVar (interp, "::viewoptions.clipping.notdomain", TCL_GLOBAL_ONLY));
if ( ! (hclip == vispar.clipping) )
{
hclip.timestamp = NextTimeStamp();
vispar.clipping = hclip;
}
vispar.whitebackground = atoi (Tcl_GetVar (interp, "::viewoptions.whitebackground", TCL_GLOBAL_ONLY));

View File

@ -124,6 +124,7 @@ set viewoptions.clipping.nx 0
set viewoptions.clipping.ny 1
set viewoptions.clipping.nz 0
set viewoptions.clipping.dist 0
set viewoptions.clipping.dist2 0
set viewoptions.clipping.enable 0
set viewoptions.clipping.onlydomain 0
set viewoptions.clipping.notdomain 0