-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi Alan,
Just before your email arrived, I sent off a new version of ps.c to
you with the -ori 2 and 3 fix. Could you put this and your changes
together in cvs, so that I can just cvs update? The fix for non-integral
values will be pretty easy, but I will wait until we are synchronized. I
didn't realize before that -ori values other than 0 and 1 were valid.
Thanks,
Tom
- --
On Sun, 5 Dec 2004, Alan W. Irwin wrote:
> On 2004-12-05 15:30-0400 Thomas J. Duck wrote:
>
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > Hi Alan,
> >
> > Here it is: the full loaf (see attached or at
> > http://aolab.phys.dal.ca/~tomduck/temp/ps.c). I had to mostly rewrite the
> > proc_str function, as I couldn't really understand the old code.
> > Hopefully you find this OK. Let me know if you have any questions about
> > what I have written.
>
> Thanks very much for your proc_str rewrite. I have tried it and like it for
> both the -ori 0 and -ori 1 case for both 2D and 3D. However, I have one
> minor nit and there are still orientation problems at any -ori value other
> than 0 or 1.
>
> ********
>
> Minor nit:
>
> Could you apply the following patch to your code so we are in synch from now
> on in these regards (some improved documentation and commentary, and return
> to the old interpretation of width that you suggested, and we agreed to).
>
> --- ps.c_tj2_original 2004-12-05 12:43:19.000000000 -0800
> +++ ps.c 2004-12-05 12:48:17.000000000 -0800
> @@ -36,11 +36,11 @@
> static int text = 0;
> static int color;
>
> -static DrvOpt ps_options[] = {{"text", DRV_INT, &text, "Use Postscript text (text=0|1|2)"},
> +static DrvOpt ps_options[] = {{"text", DRV_INT, &text, "Use Postscript text (text=0|1)"},
> {"color", DRV_INT, &color, "Use color (color=0|1)"},
> {NULL, DRV_INT, NULL, NULL}};
>
> -/* text > 1 uses some postscript tricks, namely a transformation matrix
> +/* text > 0 uses some postscript tricks, namely a transformation matrix
> that scales, rotates (with slanting) and offsets text strings.
> It has yet some bugs for 3d plots. */
>
> @@ -515,7 +515,7 @@
> case PLSTATE_WIDTH:{
> int width =
> (pls->width < MIN_WIDTH) ? DEF_WIDTH :
> - (pls->width > MAX_WIDTH) ? MAX_WIDTH : DEF_WIDTH * pls->width;
> + (pls->width > MAX_WIDTH) ? MAX_WIDTH : pls->width;
>
> fprintf(OF, " S\n%d W", width);
>
> ********
>
> The orientation problems noted above for cases other than -ori 0 or -ori 1
> are evident from the following tests:
>
> Compare results for
>
> ./x01c -dev psc -o test.ps -drvopt text=0 -ori 2.
>
> and
>
> ./x01c -dev psc -o test.ps -drvopt text=1 -ori 2.
>
> Also try plots at non-integral -ori values such as
>
> ./x01c -dev psc -o test.ps -drvopt text=0 -a 1 -ori 0.5
>
> and
>
> ./x01c -dev psc -o test.ps -drvopt text=1 -a 1 -ori 0.5
>
> (I have set the aspect ratio to unity to avoid another long-standing PLplot
> core "parallelogram bug" for non-unity aspect ratio and non-integral ori.)
>
> These bugs were not there for the previous version of the code which I just
> committed and also sent to you. That code works perfectly for the above
> tests for the 2D case, but has consistent problems for the 3D case which are
> independent of the -ori value.
>
> So one step forward (2D and 3D now works for -ori 0 and 1), one step back
> (nothing currently works for other -ori values).
>
> I hope it will be straightforward for you to make the above tests give good
> results for text=1 for both 2D (./x01c) and 3D (./x11c).
>
> Thanks very much for your help so far.
>
> Alan
> __________________________
> Alan W. Irwin
> email: irwin@...
> phone: 250-727-2902
>
> Astronomical research affiliation with Department of Physics and Astronomy,
> University of Victoria (astrowww.phys.uvic.ca).
>
> Programming affiliations with the FreeEOS equation-of-state implementation
> for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
> package (plplot.org); the Yorick front-end to PLplot (yplot.sf.net); the
> Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project
> (lbproject.sf.net).
> __________________________
>
> Linux-powered Science
> __________________________
>
- --
Thomas J. Duck <tomduck@...>
Department of Physics and Atmospheric Science, Dalhousie University,
Halifax, Nova Scotia, Canada, B3H 3J5.
Tel: (902)494-1456 | Fax: (902)494-5191 | Lab: (902)494-3813
Web: http://aolab.phys.dal.ca/~tomduck/
Public key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x17D965DB
Tier I CRC Chair in Atmospheric Science: http://www.atm.dal.ca/jobs/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
iD8DBQFBs4XundxDHhfZZdsRAsLVAKCdrK60YSzGiNhYNnpz0utOohQREQCfU5TE
k4LVtl15Iqa4awLDJXxkPTY=
=4V5/
-----END PGP SIGNATURE-----
|