1 |
< |
/* Copyright (c) 1993 Regents of the University of California */ |
1 |
> |
/* Copyright (c) 1994 Regents of the University of California */ |
2 |
|
|
3 |
|
#ifndef lint |
4 |
|
static char SCCSid[] = "$SunId$ LBL"; |
140 |
|
else { |
141 |
|
nv.horiz = ourview.horiz; nv.vert = ourview.vert; |
142 |
|
} |
143 |
+ |
sprintf(buf, "fore and aft clipping plane (%.6g %.6g): ", |
144 |
+ |
ourview.vfore, ourview.vaft); |
145 |
+ |
(*dev->comout)(buf); |
146 |
+ |
(*dev->comin)(buf, NULL); |
147 |
+ |
if (buf[0] == CTRL('C')) return; |
148 |
+ |
if (sscanf(buf, "%lf %lf", &nv.vfore, &nv.vaft) == 2) |
149 |
+ |
change++; |
150 |
+ |
else { |
151 |
+ |
nv.vfore = ourview.vfore; nv.vaft = ourview.vaft; |
152 |
+ |
} |
153 |
|
sprintf(buf, "view shift and lift (%.6g %.6g): ", |
154 |
|
ourview.hoff, ourview.voff); |
155 |
|
(*dev->comout)(buf); |
620 |
|
int x, y; |
621 |
|
RAY thisray; |
622 |
|
|
623 |
+ |
thisray.rmax = 0.0; |
624 |
+ |
|
625 |
|
if (!sscanvec(s, thisray.rorg) || |
626 |
|
!sscanvec(sskip(sskip(sskip(s))), thisray.rdir)) { |
627 |
|
|
631 |
|
if ((*dev->getcur)(&x, &y) == ABORT) |
632 |
|
return; |
633 |
|
|
634 |
< |
if (viewray(thisray.rorg, thisray.rdir, &ourview, |
635 |
< |
(x+.5)/hresolu, (y+.5)/vresolu) < 0) { |
634 |
> |
if ((thisray.rmax = viewray(thisray.rorg, thisray.rdir, |
635 |
> |
&ourview, (x+.5)/hresolu, (y+.5)/vresolu)) < -FTINY) { |
636 |
|
error(COMMAND, "not on image"); |
637 |
|
return; |
638 |
|
} |