go to www.geomview.org home page
 
Home

Overview
FAQ
Documentation

Download

Mailing List

Geomview For Windows?

Support
Users
Development

Bug Reporting
Contributing
Contact Us

Sponsors

 

Site Search

 

Advanced
Search

 
About the software@geom archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Stereo



To get red/green stereo, you could replace draw_view() with the following
routine, in Geomview/src/bin/geomview/common/drawer.c:

static void
draw_view(register DView *dv)
{
	/* Colors for red/cyan stereo */
  static int lefteyemask = MGO_NOGREEN|MGO_NOBLUE;	/* Red */
  static int righteyemask = MGO_NORED|MGO_NOBLUE;	/* Green */
  Appearance *ap;

  if(!dv->frozen && (dv->redraw || dv->changed || dv->newcam)) {
    mgctxselect(dv->mgctx);
    mgctxset(MG_BACKGROUND, &dv->backcolor, MG_CAMERA, dv->cam,
	     MG_ZNUDGE, dv->lineznudge * 1.0e-5,
	     MG_UNSETOPTIONS,
		MGO_NORED|MGO_NOGREEN|MGO_NOBLUE|MGO_INHIBITCLEAR,
	     MG_END);
    if(drawerstate.apseq > dv->apseq) {
      mgsetappearance(drawerstate.ap, MG_SET);
      dv->apseq = drawerstate.apseq;
    }
    ap = GeomAppearance(dv->Item);
    if(ap)
      mgsetappearance(ap, MG_MERGE);

    if(dv->newcam)
	reconfigure_view(dv);
    if(dv->stereo != NO_KEYWORD) {
	mgctxset(MG_WnSet, WN_VIEWPORT, &dv->vp[1], WN_END,
		MG_CamSet, CAM_STEREOEYE, 1, CAM_END,
		MG_SETOPTIONS, MGO_INHIBITSWAP, MG_END);
	if(dv->stereo == COLORED_KEYWORD)
	    mgctxset(MG_SETOPTIONS, lefteyemask, MG_END);
	really_draw_view(dv);
	mgctxset(MG_WnSet, WN_VIEWPORT, &dv->vp[0], WN_END,
		MG_CamSet, CAM_STEREOEYE, 0, CAM_END,
		MG_UNSETOPTIONS, MGO_INHIBITSWAP|lefteyemask,
			MG_END);
	if(dv->stereo == COLORED_KEYWORD)
	    mgctxset(MG_SETOPTIONS, righteyemask|MGO_INHIBITCLEAR, MG_END);
	
    }
    really_draw_view(dv);
    dv->changed = dv->redraw = 0;
  }
}


Changing red/cyan => red/green should improve things if the monitor's *blue*
phosphor is visible in your red eye lens.  However, if the green lens is
showing both red & cyan images, this probably won't help -- you'd need either
different glasses or a different monitor.

Good luck!


 
Home | Overview | FAQ | Documentation | Support | Download | Mailing List
Windows? | Development | Bug Reporting | Contributing | Contact Us | Sponsors
 
site hosted by
SourceForge Logo