Hi,
Thanks, this is a huge help!
Me thinks I found a bug. If I call setAspect2 before I add data to the
display, the data are not positioned properly. Let me know if you'd like
me to send some sample code.
Thanks,
Doug
Bill Hibbard wrote:
>
> There are now two methods in ProjectionControl for setting
> aspect ratio:
>
> public void setAspect(double[] aspect)
> throws VisADException, RemoteException;
>
> public void setAspect2(double[] aspect)
> throws VisADException, RemoteException;
>
> The first is the same implementation that has been available
> previously. This has the negative affect of squashing text
> and other line graphics, and making unrealistic normals for
> shading.
>
> The second eliminates the negative affects. Note however it
> is only appropriate for displays with ScalarMaps to XAxis,
> YAxis and ZAxis. Displays based on spherical and other non-
> Cartesian spatial coordinates are unaffected by setAspect2().
>
> I have changed Test57.java and Test58.java in visad/examples
> to use setAspect2(). Note that Test57.java actually combines
> both methods:
>
> control.setAspect2(new double[] {2.0, 1.0, 0.5});
> control.setAspect(new double[] {0.5, 0.5, 0.5});
>
> Passing aspect numbers larger than 1.0 to setAspect2() avoids
> text collisions in axis scales, then passing three identical
> values (i.e., 0.5) to setAspect() scales the scene to fit in
> the window.
>
> Cheers,
> Bill
> ----------------------------------------------------------
> Bill Hibbard, SSEC, 1225 W. Dayton St., Madison, WI 53706
> hibbard@xxxxxxxxxxxxxxxxx 608-263-4427 fax: 608-263-6738
> http://www.ssec.wisc.edu/~billh/vis.html
--
*----------------------------------------------------------------------*
| Doug Lindholm, Software Engineer | E-mail: lind@xxxxxxxx |
| Research Applications Program | Phone: 303-497-8374 |
| National Center for Atmospheric Research | |
| P.O. Box 3000 | There's no place |
| Boulder, Colorado 80307-3000 | like $HOME |
*----------------------------------------------------------------------*