~ubuntu-branches/ubuntu/intrepid/plplot/intrepid

« back to all changes in this revision

Viewing changes to src/plpage.c

  • Committer: Bazaar Package Importer
  • Author(s): Rafael Laboissiere
  • Date: 2006-11-04 10:19:34 UTC
  • mfrom: (2.1.8 edgy)
  • Revision ID: james.westby@ubuntu.com-20061104101934-mlirvdg4gpwi6i5q
Tags: 5.6.1-10
* Orphaning the package
* debian/control: Changed the maintainer to the Debian QA Group

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $Id: plpage.c,v 1.27 2004/01/17 16:41:40 rlaboiss Exp $
 
1
/* $Id: plpage.c,v 1.29 2005/04/27 06:44:25 rlaboiss Exp $
2
2
 
3
3
        Page/subpage handling routines
4
4
 
18
18
 
19
19
   You should have received a copy of the GNU Library General Public License
20
20
   along with PLplot; if not, write to the Free Software
21
 
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 
21
   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
22
22
*/
23
23
 
24
24
#include "plplotP.h"
134
134
void
135
135
plP_subpInit(void)
136
136
{
137
 
    PLFLT scale, size_chr, size_sym, size_maj, size_min;
 
137
    PLFLT scale, size_chr, size_sym, size_maj, size_min, theta, rat;
138
138
 
139
139
/* Subpage checks */
140
140
 
158
158
        ((plsc->phyxma - plsc->phyxmi) / plsc->xpmm +
159
159
         (plsc->phyyma - plsc->phyymi) / plsc->ypmm) / 200.0;
160
160
 
 
161
    /* Take account of scaling caused by change of orientation */
 
162
    if (plsc->difilt && PLDI_ORI) {
 
163
      theta = 0.5*M_PI*plsc->diorot;
 
164
      rat = ( (plsc->phyxma - plsc->phyxmi) / plsc->xpmm ) / 
 
165
        ( (plsc->phyyma - plsc->phyymi) / plsc->ypmm );
 
166
      rat = MAX(rat,1.0/rat);
 
167
      rat = fabs(cos(theta)) + rat*fabs(sin(theta));
 
168
      scale /= rat;
 
169
    }
 
170
 
161
171
    if (plsc->nsuby > 1)
162
172
        scale /= sqrt((double) plsc->nsuby);
163
173