home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 1: Amiga
/
FrozenFish-Apr94.iso
/
bbs
/
alib
/
d2xx
/
d222
/
plplot.lha
/
Plplot
/
src
/
source.zoo
/
icnvrt.c
< prev
next >
Wrap
C/C++ Source or Header
|
1989-05-15
|
787b
|
50 lines
/* Coordinate transformations for plotting package */
/* Convertion routines yielding an integer result */
#include "plplot.h"
#include "declare.h"
/* dcpc. converts device coordinates to physical coordinates */
int dcpcx(x)
float x;
{
return(round(dpxoff + dpxscl * x));
}
int dcpcy(y)
float y;
{
return(round(dpyoff + dpyscl * y));
}
/* mmpc. converts millimetres from bottom left-hand corner to physical */
/* coordinates */
int mmpcx(x)
float x;
{
return(round(mpxoff + mpxscl * x));
}
int mmpcy(y)
float y;
{
return(round(mpyoff + mpyscl * y));
}
/* wcpc. converts world coordinates to physical coordinates */
int wcpcx(x)
float x;
{
return(round(wpxoff + wpxscl * x));
}
int wcpcy(y)
float y;
{
return(round(wpyoff + wpyscl * y));
}