Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project!

## Re: [Plplot-devel] Parallelogram problem for rotation

 Re: [Plplot-devel] Parallelogram problem for rotation From: Arjen Markus - 2003-11-18 07:31:36 ```Jo=E3o Cardoso wrote: >=20 > On Monday 17 November 2003 03:46, Jo=E3o Cardoso wrote: > | Hi, > | > | In the PROBLEMS file we can find the following entry: > | > | * Parallelogram problem for rotation which is not multiple of 90 deg. > | This is on the major list because Maurice doesn't think it will be > | simple to sort this out. Once this problem is sorted out, it should > | be possible to deal with the remaining rotation problems for the font > | handling, but those issues should not be tackled until the > | parallelogram core problem is straightened out. > | > | As a matter of fact there is no such problem. The symptom is a result > | of the default aspect ratio. >=20 > I was wrong, there is a problem, as it is not OK that an aspect ratio != =3D > 1 streches a rectangle when rotating it. If two sides are rotated by > the same angle, the angle between the sides is kept constant, > obviously. >=20 > However, the problem is *induced* by the aspect ratio, as there is no > problem when the aspect ration is 1. > What must be happening is that first a rotation is performed and after > that a strech is performed to fit the aspect ratio. If one rotates a > rectangle an then streches it, the observed problem is reproduced. >=20 Hm, I have been following this thread with intellectual curiosity: I think the problem (if there is a programming problem) is caused=20 by the fact that there are two different operations in two different coordinate systems that need to cooperate. The rotation takes place in, say, the world coordinates system. The mapping to the screen takes place in the screen coordinates system. With an aspect ratio of 1, the mapping is isometric, with any other=20 value, it is not.=20 Unless the rotation takes place in the screen coordinates system too, you will always have this bizarre problem. In my view, the problem is one of perception and definition. Sort that one out and the implementation will follow. Regards, Arjen ```

 [Plplot-devel] Parallelogram problem for rotation From: - 2003-11-17 03:47:18 ```Hi, In the PROBLEMS file we can find the following entry: * Parallelogram problem for rotation which is not multiple of 90 deg. This is on the major list because Maurice doesn't think it will be simple to sort this out. Once this problem is sorted out, it should be possible to deal with the remaining rotation problems for the font handling, but those issues should not be tackled until the parallelogram core problem is straightened out. As a matter of fact there is no such problem. The symptom is a result of the default aspect ratio. If one try ./x01c -dev xwin -a 1 -ori [0-3].[0-9] The problem vanish. I discovered this while investigating the -drvopt text rotation problem (which I still can't completely solve!). As a matter of fact, the aspect ratio has several incarnations in plstrm.h, which mix up in plcore.c, at least. This needs some reasoning and code cleanup. Besides, even if the aspect ratio is specified, plot window resizes under the xwin driver don't honor the aspect ratio, and should. How should the aspect ratio be handled? Joao ```
 Re: [Plplot-devel] Parallelogram problem for rotation From: Alan W. Irwin - 2003-11-17 05:50:46 ```On 2003-11-17 03:46-0000 Jo=E3o Cardoso wrote: > As a matter of fact there is no such problem. The symptom is a result of = the > default aspect ratio. If one try > > =09./x01c -dev xwin -a 1 -ori [0-3].[0-9] > > The problem vanish. I agree the problem disappears for unity aspect ratio. This was mentioned in the original thread about this although not in the short summary in PROBLEMS. By the way, it is not just the default aspect ratio. Try any non-unity aspect ratio and any angle which is not an even multiple of 45 de= g and the parallelogram problem appears. For an extreme example compare =2E/x01c -a .25 -dev xwin -ori .25 with =2E/x01c -a .25 -dev xwin -ori .5 Although it is a neat feature to be able to rotate plots by arbitrary angle= s few use this facility so fixing this parallelogram bug is obviously a low-priority item. Nevertheless, perhaps there is somebody in this group willing to trace through and debug the logic of the core aspect-ratio and orientation code simply for the intellectual challenge? 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 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 __________________________ ```
 Re: [Plplot-devel] Parallelogram problem for rotation From: - 2003-11-17 14:43:13 ```On Monday 17 November 2003 05:49, Alan W. Irwin wrote: | On 2003-11-17 03:46-0000 Jo=E3o Cardoso wrote: | > As a matter of fact there is no such problem. The symptom is a | > result of the default aspect ratio. If one try | > | > ./x01c -dev xwin -a 1 -ori [0-3].[0-9] | > | > The problem vanish. | | I agree the problem disappears for unity aspect ratio. This was | mentioned in the original thread about this although not in the short | summary in PROBLEMS. By the way, it is not just the default aspect | ratio. Try any non-unity aspect ratio and any angle which is not an | even multiple of 45 deg and the parallelogram problem appears. For | an extreme example compare | | | ./x01c -a .25 -dev xwin -ori .25 | | with | | ./x01c -a .25 -dev xwin -ori .5 | | Although it is a neat feature to be able to rotate plots by arbitrary | angles few use this facility so fixing this parallelogram bug is | obviously a low-priority item. Nevertheless, perhaps there is | somebody in this group willing to trace through and debug the logic | of the core aspect-ratio and orientation code simply for the | intellectual challenge? The PROBLEMS file says: Once this problem is sorted out, it should be possible to deal with the remaining rotation problems for the font handling, but those issues should not be tackled until the parallelogram core problem is straightened out. This implies that there is a problem, and there is none. You call it=20 "parallelogram" problem, but it is not; if you try x03, that should=20 draw a circle, you see an ellipses, is it the circle problem? How should the text be draw? using the specified "-ori orientation" or=20 the real orientation induced by a non unity aspect ratio? And what do you want the "intellectual challenged" person to debug?=20 There exists a bug or not? The only bug I see is the fact that resizing the plot window does not=20 preserves the specified aspect ratio. | | 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 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 | __________________________ | | | ------------------------------------------------------- | This SF. Net email is sponsored by: GoToMyPC | GoToMyPC is the fast, easy and secure way to access your computer | from any Web browser or wireless device. Click here to Try it Free! | https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target___________ |____________________________________ Plplot-devel mailing list | Plplot-devel@... | https://lists.sourceforge.net/lists/listinfo/plplot-devel ```
 Re: [Plplot-devel] Parallelogram problem for rotation From: Alan W. Irwin - 2003-11-17 16:29:35 ```On 2003-11-17 14:40-0000 Jo=E3o Cardoso wrote: > | I agree the problem disappears for unity aspect ratio. This was > | mentioned in the original thread about this although not in the short > | summary in PROBLEMS. By the way, it is not just the default aspect > | ratio. Try any non-unity aspect ratio and any angle which is not an > | even multiple of 45 deg and the parallelogram problem appears. For > | an extreme example compare > | > | > | ./x01c -a .25 -dev xwin -ori .25 > | > | with > | > | ./x01c -a .25 -dev xwin -ori .5 > | > The only bug I see is the fact that resizing the plot window does not > preserves the specified aspect ratio. Joao may well have found an additional resizing bug which is probably not related to the "parallelogram" bug. If you look at the results from the above two examples, the second is fine, but for the first the angles of the plot box rectangle are no longer 90 deg= =2E In other words, the plot box has turned into a parallelogram; the geometry has been sheared as well as rotated. That is a bug. Joao, can you look very carefully again please at the first example? The others here should d= o this as well. If some of us have the problem and others do not, that would be an interesting clue as to the nature of the problem. On my system, the native Hershey fonts also follow this sheared parallelogram geometry so the result does not look too bad. But if you try non-native fonts (which have correct geometry with no shearing) the labels do not line up exactly with the sides of the sheared plot box, and the result looks horrible. But the point is this is not a problem with the geometry of the non-native fonts. Instead, it is a problem with the plplot core geometry (and native font geometry) for the combination of non-unity aspect ratios and angles which are not even multiples of 45 deg as in the first example above. All this was covered in the original thread, and the PROBLEMS entry is simply a quick and dirty summary to remind us of that thread. If anybody who re-confirms the problem now wants to modify that summary, just go ahead= =2E 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 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 __________________________ ```
 Re: [Plplot-devel] Parallelogram problem for rotation From: - 2003-11-17 20:24:39 ```On Monday 17 November 2003 03:46, Jo=E3o Cardoso wrote: | Hi, | | In the PROBLEMS file we can find the following entry: | | * Parallelogram problem for rotation which is not multiple of 90 deg. | This is on the major list because Maurice doesn't think it will be | simple to sort this out. Once this problem is sorted out, it should | be possible to deal with the remaining rotation problems for the font | handling, but those issues should not be tackled until the | parallelogram core problem is straightened out. | | As a matter of fact there is no such problem. The symptom is a result | of the default aspect ratio. I was wrong, there is a problem, as it is not OK that an aspect ratio !=3D= =20 1 streches a rectangle when rotating it. If two sides are rotated by=20 the same angle, the angle between the sides is kept constant,=20 obviously. However, the problem is *induced* by the aspect ratio, as there is no=20 problem when the aspect ration is 1. What must be happening is that first a rotation is performed and after=20 that a strech is performed to fit the aspect ratio. If one rotates a=20 rectangle an then streches it, the observed problem is reproduced. Joao | If one try | | ./x01c -dev xwin -a 1 -ori [0-3].[0-9] | | The problem vanish. | I discovered this while investigating the -drvopt text rotation | problem (which I still can't completely solve!). | | As a matter of fact, the aspect ratio has several incarnations in | plstrm.h, which mix up in plcore.c, at least. This needs some | reasoning and code cleanup. | | Besides, even if the aspect ratio is specified, plot window resizes | under the xwin driver don't honor the aspect ratio, and should. | | How should the aspect ratio be handled? | | Joao | | | ------------------------------------------------------- | This SF. Net email is sponsored by: GoToMyPC | GoToMyPC is the fast, easy and secure way to access your computer | from any Web browser or wireless device. Click here to Try it Free! | https://www.gotomypc.com/tr/OSDN/AW/Q4_2003/t/g22lp?Target=3Dmm/g22lp.t |mpl _______________________________________________ | Plplot-devel mailing list | Plplot-devel@... | https://lists.sourceforge.net/lists/listinfo/plplot-devel ```
 Re: [Plplot-devel] Parallelogram problem for rotation From: Arjen Markus - 2003-11-18 07:31:36 ```Jo=E3o Cardoso wrote: >=20 > On Monday 17 November 2003 03:46, Jo=E3o Cardoso wrote: > | Hi, > | > | In the PROBLEMS file we can find the following entry: > | > | * Parallelogram problem for rotation which is not multiple of 90 deg. > | This is on the major list because Maurice doesn't think it will be > | simple to sort this out. Once this problem is sorted out, it should > | be possible to deal with the remaining rotation problems for the font > | handling, but those issues should not be tackled until the > | parallelogram core problem is straightened out. > | > | As a matter of fact there is no such problem. The symptom is a result > | of the default aspect ratio. >=20 > I was wrong, there is a problem, as it is not OK that an aspect ratio != =3D > 1 streches a rectangle when rotating it. If two sides are rotated by > the same angle, the angle between the sides is kept constant, > obviously. >=20 > However, the problem is *induced* by the aspect ratio, as there is no > problem when the aspect ration is 1. > What must be happening is that first a rotation is performed and after > that a strech is performed to fit the aspect ratio. If one rotates a > rectangle an then streches it, the observed problem is reproduced. >=20 Hm, I have been following this thread with intellectual curiosity: I think the problem (if there is a programming problem) is caused=20 by the fact that there are two different operations in two different coordinate systems that need to cooperate. The rotation takes place in, say, the world coordinates system. The mapping to the screen takes place in the screen coordinates system. With an aspect ratio of 1, the mapping is isometric, with any other=20 value, it is not.=20 Unless the rotation takes place in the screen coordinates system too, you will always have this bizarre problem. In my view, the problem is one of perception and definition. Sort that one out and the implementation will follow. Regards, Arjen ```