Re: Top-bottom stereo

New Message Reply Date view Thread view Subject view Author view

From: Angus Dorbie (dorbie++at++sgi.com)
Date: 03/08/2001 09:26:23


You have a heading offset and identical frusta (although I don't see the
rght eye FOV call I do see the left eye symmetric FOV), this is
fundamentally flawed approach to stereo. It's also exactly the kind of
thing which leads to objects moving across the FOV to separate in
diverging directions.

You are doing classic bad stereo projection. See my earlier post for the
correct approach.

Also for STR_RECT stereo there is a blanking region in the middle, so
it's not strictly correct to have viewports o to .5 and .5 to 1, I'm not
sure what the gap should be.

Cheers,Angus.

"G. Anthony Reina" wrote:
>
> Thanks to several suggestions from the list, I've managed to get
> 2-channel (top-bottom) stereo pretty much working on my Octane using
> STR_RECT as the setmon. There seems to be only one thing that's off: the
> left and right views are slightly offset in the vertical dimension. When
> I move the 3D object in and out, the two views move off at a diagonal
> rather than parallel to the horiztonal plane (as they should).
>
> Can anyone think of what I'm doing wrong here?
>
> Thanks.
> -Tony
>
> Procedure:
> (1) I'm using /usr/gfx/setmon -n STR_RECT to set the screen resolution
> to 1280x1024_60s for top-bottom stereo
> (2) I'm creating an X window in performer that is 1280 x 1024:
> pfPWinOriginSize(win, 0, 0, 1280, 1024);
> (3) I'm setting the left and right channels to different viewports of
> that window:
> pfChanViewport(left_chan, 0.0, 1.0, 0.5, 1.0);
> pfChanViewport(right_chan, 0.0, 1.0, 0.0, 0.5);
> (4) I'm setting the aspect ratio and aspect views:
>
> Iod = 50; /* (in mm) */
> Converge = 300 ; /* (in mm) */
> pfChanFOV(left_chan, 45.0f, 36.0f);
> eyeAngle = PF_RAD2DEG(atanf(Iod*.5f/Converge));
>
> /* Left eye */
> pfSetVec3(hprOffsets, -eyeAngle, 0.0f, 0.0f);
> pfSetVec3(xyzOffsets, -Iod/2.f, 0.0f, 0.0f);
> pfChanViewOffsets(left_chan, xyzOffsets, hprOffsets);
>
> /* Right eye */
> pfSetVec3(hprOffsets, eyeAngle, 0.0f, 0.0f);
> pfSetVec3(xyzOffsets, Iod/2.f, 0.0f, 0.0f);
> pfChanViewOffsets(right_chan, xyzOffsets, hprOffsets);
>
> pfChanTravMode(left_chan, PFTRAV_CULL, PFCULL_VIEW|PFCULL_GSET);
>
> pfSetVec3(view.xyz, 0.f, -Converge, 0.f);
> pfSetVec3(view.hpr, 0.0f, 0.0f, 0.0f);
> pfChanView(left_chan, view.xyz, view.hpr);
>
> -----------------------------------------------------------------------
> List Archives, FAQ, FTP: http://www.sgi.com/software/performer/
> Open Development Project: http://oss.sgi.com/projects/performer/
> Submissions: info-performer++at++sgi.com
> Admin. requests: info-performer-request++at++sgi.com

-- 
For Performer+OpenGL tutorials http://www.dorbie.com/

"Whenever there is a conflict between human rights and property rights, human rights must prevail." --Abraham Lincoln


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Thu Mar 08 2001 - 13:06:02 PST

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.