aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/detector.c6
-rw-r--r--src/detector.h8
2 files changed, 7 insertions, 7 deletions
diff --git a/src/detector.c b/src/detector.c
index e53d5331..b9d91118 100644
--- a/src/detector.c
+++ b/src/detector.c
@@ -32,7 +32,7 @@ static int atob(const char *a)
}
-static int dir_conv(const char *a, signed int *sx, signed int *sy)
+static int dir_conv(const char *a, double *sx, double *sy)
{
if ( strcmp(a, "-x") == 0 ) {
*sx = -1; *sy = 0;
@@ -79,8 +79,8 @@ struct rvec get_q(struct image *image, double fs, double ss,
/* Convert xs and ys, which are in fast scan/slow scan coordinates,
* to x and y */
- xs = (fs-p->min_fs)*p->fsx + (ss-p->min_ss)*p->ssx;
- ys = (fs-p->min_fs)*p->fsy + (ss-p->min_ss)*p->ssy;
+ xs = (fs-(double)p->min_fs)*p->fsx + (ss-(double)p->min_ss)*p->ssx;
+ ys = (fs-(double)p->min_fs)*p->fsy + (ss-(double)p->min_ss)*p->ssy;
rx = (xs + p->cnx) / p->res;
ry = (ys + p->cny) / p->res;
diff --git a/src/detector.h b/src/detector.h
index 028bd589..c4e06cef 100644
--- a/src/detector.h
+++ b/src/detector.h
@@ -38,10 +38,10 @@ struct panel
int no_index; /* Don't index peaks in this panel if non-zero */
double peak_sep; /* Characteristic peak separation */
- signed int fsx;
- signed int fsy;
- signed int ssx;
- signed int ssy;
+ double fsx;
+ double fsy;
+ double ssx;
+ double ssy;
double xfs;
double yfs;