1 |
< |
/* Copyright (c) 1998 Silicon Graphics, Inc. */ |
1 |
> |
/* Copyright (c) 1999 Silicon Graphics, Inc. */ |
2 |
|
|
3 |
|
#ifndef lint |
4 |
|
static char SCCSid[] = "$SunId$ SGI"; |
284 |
|
{ |
285 |
|
viewflags |= VWCHANGE; /* pretend our view has changed */ |
286 |
|
wipeclean(); /* clean off display and samples */ |
287 |
+ |
dev_flush(); /* redraw geometry & get depth */ |
288 |
|
rayqleft = 0; /* hold off update */ |
289 |
|
} |
290 |
|
|
373 |
|
char *cmd, *args; |
374 |
|
{ |
375 |
|
#ifdef DOBJ |
376 |
< |
if (dobj_command(cmd, args) >= 0) |
376 |
> |
int vischange; |
377 |
> |
|
378 |
> |
if ((vischange = dobj_command(cmd, args)) >= 0) { |
379 |
> |
if (vischange) { |
380 |
> |
imm_mode = beam_sync(1) > 0; |
381 |
> |
dev_clear(); |
382 |
> |
} |
383 |
|
return; |
384 |
+ |
} |
385 |
|
#endif |
386 |
|
sprintf(errmsg, "%s: unknown command", cmd); |
387 |
|
error(COMMAND, errmsg); |
517 |
|
else |
518 |
|
pbuf = NULL; |
519 |
|
#ifdef STEREO |
520 |
< |
setstereobuf(STEREO_BUFFER_RIGHT); |
520 |
> |
pushright(); |
521 |
|
glReadPixels(0, 0, odev.hres, odev.vres, |
522 |
|
GL_DEPTH_COMPONENT, GL_FLOAT, depthright); |
523 |
|
if (pbuf != NULL) { |
532 |
|
else |
533 |
|
*dbp = mapdepth(*dbp); |
534 |
|
glClear(GL_DEPTH_BUFFER_BIT); |
527 |
– |
setstereobuf(STEREO_BUFFER_LEFT); |
535 |
|
odDepthMap(1, depthright); |
536 |
+ |
popright(); |
537 |
|
#endif |
538 |
|
/* read back depth buffer */ |
539 |
|
glReadPixels(0, 0, odev.hres, odev.vres, |
857 |
|
dev_zmax = 100.; |
858 |
|
} else { |
859 |
|
dev_zmin = 0.5*depthlim[0]; |
860 |
< |
dev_zmax = 2.0*depthlim[1]; |
860 |
> |
dev_zmax = 1.25*depthlim[1]; |
861 |
|
if (dev_zmin > dev_zmax/5.) |
862 |
|
dev_zmin = dev_zmax/5.; |
863 |
|
} |
1002 |
|
return; |
1003 |
|
case CTRL('L'): /* refresh from server */ |
1004 |
|
if (inpresflags & DFL(DC_REDRAW)) |
1005 |
< |
return; |
1005 |
> |
return; /* already called */ |
1006 |
|
XRaiseWindow(ourdisplay, gwind); |
1007 |
|
XFlush(ourdisplay); /* raise up window */ |
1008 |
|
sleep(1); /* wait for restacking */ |
1009 |
|
dev_clear(); /* clear buffer and samples */ |
1010 |
|
odRemap(1); /* start fresh histogram */ |
1003 |
– |
dev_flush(); /* redraw geometry */ |
1004 |
– |
rayqleft = 0; /* hold off update */ |
1011 |
|
inpresflags |= DFL(DC_REDRAW); /* resend values from server */ |
1012 |
|
return; |
1013 |
|
case 'K': /* kill rtrace process(es) */ |