[comp.sys.sgi] StereoView raster sizes

sdempsey@UCSD.EDU (Steve Dempsey) (08/11/90)

Recently I was looking at some stereo images on a 340VGX with StereoView 
and I noticed that that they seemed slightly compressed along the vertical
axis.  I ran a test program to generate some rasters of a known size and
then measured the raster heights.  My initial assumption was that a raster
with a height of 492 pixels and displayed with setmonitor(STR_RECT) should have
the same height as a raster of 984 pixels displayed with setmonitor(HZ60).

Instead, I found that the stereo raster was about 6% smaller than I expected.
Now that I know the value of this factor I can adjust the aspect ratio
of my projection transformations to compensate, but I was wondering if
other people have seen this and if they measure the same shrinkage factor.

Here is the program I used to draw the rasters:

#include <gl.h>
#include <get.h>
#include <device.h>

main()
	{
	int	val, type;

	noborder();
	prefposition(0, 1279, 0, 1023);
	winopen("");
/*
* The middle mouse toggles between the two rasters
*/
	qdevice(MIDDLEMOUSE);
	type = 0;
	while(qread(&val))
	    {
	    if(val) continue;
	    type = !type;
	    if( type )
/*
* color a full screen stereo window area (1280x492 pixels),
* then switch the monitor to STEREO mode so the raster size can be measured.
*/
		{
		viewport(0, 1279, 0, 1023);
		color(BLUE);
		clear();
		color(RED);
		viewport(0, 1279, 0, 491);
		clear();
		viewport(0, 1279, 532, 1023);
		clear();
		setmonitor(STR_RECT);
		}
	    else
/*
* color a window area 984 pixels high, which should generate the same size
* raster as a 492 pixel window in Stereo mode.
*/
		{
		viewport(0, 1279, 0, 1023);
		color(BLUE);
		clear();
		color(GREEN);
		viewport(0, 1279, 20, 1003);
		clear();
		setmonitor(HZ60);
		}
	    }
	}
--------------------------------------------------------------------------------
Steve Dempsey						       (619) 534-0208
Dept. of Chemistry Computer Facility, B-014	   INTERNET:   sdempsey@ucsd.edu
University of Calif. at San Diego		     BITNET:   sdempsey@ucsd
La Jolla, CA 92093				       UUCP:   ucsd!sdempsey

thant@horus.esd.sgi.com (Thant Tessman) (08/14/90)

In article <9008102119.AA04851@chem.chem.ucsd.edu>, sdempsey@UCSD.EDU
(Steve Dempsey) writes:
> Recently I was looking at some stereo images on a 340VGX with StereoView 
> and I noticed that that they seemed slightly compressed along the vertical
> axis.  I ran a test program to generate some rasters of a known size and
> then measured the raster heights.  My initial assumption was that a raster
> with a height of 492 pixels and displayed with setmonitor(STR_RECT)
should have
> the same height as a raster of 984 pixels displayed with setmonitor(HZ60).
> 
> Instead, I found that the stereo raster was about 6% smaller than I expected.
> Now that I know the value of this factor I can adjust the aspect ratio
> of my projection transformations to compensate, but I was wondering if
> other people have seen this and if they measure the same shrinkage factor.

I assume it is because you have a Mitsubishi Diamondscan multisync 
monitor.  This monitor is a little too smart.  When the stereo stuff
was first done by StereoGraphics, they modified the monitors to double
the vertical displacement.  This made the pixels twice as high as they
were wide.  The proper aspect ratio for the window was 1280 in 'x' to 
492X2 in 'y'.

But since 40 scan lines were missing (used for vertical blank), the 
total picture height was slightly less than the non-stereo image.
SGI's stereo (and the newer StereoGraphics stereo) uses a Mitsubishi 
multisync monitor.  It does all adjustments digitally, and it 
automatically adjusts for a different number of scanlines by 
stretching the scanlines available to fit the area stored in its 
memory.

In other words, it stretches the 492 stereo scanlines to 
fit into the same place that 1024 scanlines fit in non-stereo
mode.  This makes the pixels higher by 2.08 instead of 2, or 
stretched vertically by about 4%.  This means that if you want
to compensate for it in a window that is 1280 by 492, the aspect
ratio should be 1280 to 1024, or 1.25.

Unfortunately, all this means that an image that is exactly correct
for the Mitsubishi is slightly incorrect for other monitors and
vice versa.  SGI's marketing wasn't sure that 4% incompatibility 
was a big enough concern to go with a custom modified (higher 
cost) monitor.  

Another solution is to adjust the monitor to be correct for 
stereo mode and slightly incorrect for the non-stereo mode.

Hope this helps.

> Steve Dempsey						       (619) 534-0208
> Dept. of Chemistry Computer Facility, B-014	   INTERNET:   sdempsey@ucsd.edu
> University of Calif. at San Diego		     BITNET:   sdempsey@ucsd
> La Jolla, CA 92093				       UUCP:   ucsd!sdempsey

thant

sdempsey@UCSD.EDU (Steve Dempsey) (08/15/90)

     >Date: 13 Aug 90 19:20:55 GMT
     >From: Thant Tessman <sgi!shinobu!odin!horus.esd.sgi.com!thant@ucbvax.berkeley.edu>
     >Organization: Silicon Graphics Inc.
     >Subject: Re: StereoView raster sizes
     >References: <9008102119.AA04851@chem.chem.ucsd.edu>

[ stuff deleted]

     >I assume it is because you have a Mitsubishi Diamondscan multisync 
     >monitor.  This monitor is a little too smart.  When the stereo stuff

Yes, we have the Mitsubishi monitor, and what a great monitor it is!
I made the mistake of daisy chaining a Hitachi (from a 4D/25) to it so that I
could compare them side by side, and now people here complain about how
'fuzzy' the Hitachi looks.

[ stuff deleted]
     >In other words, it stretches the 492 stereo scanlines to 
     >fit into the same place that 1024 scanlines fit in non-stereo
     >mode.  This makes the pixels higher by 2.08 instead of 2, or 
     >stretched vertically by about 4%.  This means that if you want
     >to compensate for it in a window that is 1280 by 492, the aspect
     >ratio should be 1280 to 1024, or 1.25.
     >

I seem to have the opposite problem.  Rather than stretch the 492 stereo
scan lines to match 1024 regular scan lines, or even 984 scan lines,
my monitor matches them to about 928!  So now I wonder if I have a
hardware or software problem with my monitor?  I guess it's time to make
use of the maintenance contract and let the Hotline figure it out!
--------------------------------------------------------------------------------
Steve Dempsey						       (619) 534-0208
Dept. of Chemistry Computer Facility, B-014	   INTERNET:   sdempsey@ucsd.edu
University of Calif. at San Diego		     BITNET:   sdempsey@ucsd
La Jolla, CA 92093				       UUCP:   ucsd!sdempsey

lmeyer@well.sf.ca.us (lhary meyer) (08/18/90)

Steve I hope you got my mai on the subject. Have you adjusted the vertical
height on the MItsubishi to the aspect ratio you like? You might need to 
compromise between the stereo & planar modes. Set the mode switch inside the
little door to "0". Then select the function you want to tweak on the other
rotary switch. (The left slide switch needs to be in "adjust"). Press the 
little button on the lower right (cant remember the label), and the green LED
will flash. Use + / - to set to taste , then hit the lower right button again.
This will memorize the setting. I think vertical size is function 5.

The Mits is a nice monitor and the newer HL6915 is even better!

    -------- 00 --------   Lhary Meyer    Stereographics