IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 5386


Ignore:
Timestamp:
Oct 19, 2005, 9:20:19 PM (21 years ago)
Author:
eugene
Message:

fixed unit-ed value compile errors

Location:
trunk/Ohana/src
Files:
43 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/addstar/doc/Changes.txt

    r5239 r5386  
     1
     22005.10.19
     3
     4        I have added the client / server mode, and tested it out to a
     5        fair degree.  It handles all of the available addstar modes,
     6        including -ref and -cat.  A handful of things still need to be
     7        done, including pushing some of the logic to enforce sorting
     8        into the dvo load_catalog functions.  Also, I need to correct
     9        the idiosyncratic problem with sky vs Myyyy for the skyprobe
     10        data.  There are a handful of other improvements that are
     11        needed before addstar / DVO is ready for IPP release.
     12        However, at this point, it is ready for internal use by the
     13        grad students, but not yet ready for CFHT use with Elixir.
    114
    2152005.10.07
  • trunk/Ohana/src/addstar/src/get2mass.c

    r5328 r5386  
    2828
    2929  for (i = 0; i < Nregions; i++) {
     30    refcat = NULL;
    3031    switch (mode) {
    3132      case 0:
  • trunk/Ohana/src/addstar/src/get2mass_as.c

    r5328 r5386  
    1616 
    1717  int FilterSkip, TimeSkip;
    18   int Nstars, NSTARS, Nbyte, Nextra, code, Qentry;
     18  int Nstars, NSTARS, Nbyte, Nextra, Qentry;
    1919  Stars *stars;
    2020  gzFile gf;
     
    3333  DEC1 = MIN (patch[0].DEC[1], UserPatch.DEC[1]);
    3434
    35   FilterSkip = TimeSkip = 0;
     35  FilterSkip = TimeSkip = Qentry = 0;
    3636  if (photcode == TM_J) {
    3737      FilterSkip = 6;
     
    102102      stars[Nstars].M     = M;
    103103      stars[Nstars].dM    = dM;
    104       stars[Nstars].code  = code;
     104      stars[Nstars].code  = photcode;
    105105      stars[Nstars].t     = time;
    106106      stars[Nstars].found = -1;
  • trunk/Ohana/src/gastro/src/gastro.c

    r2435 r5386  
    4646  fprintf (stderr, "good solution: %f %f (%d stars)\n", dR, (dR / sqrt(1.0*Nmatch)), Nmatch);
    4747
     48  Nminterms = MIN_MATCHES;
    4849  switch (NPOLYTERMS) {
    4950  case 0:
  • trunk/Ohana/src/gastro/src/gaussj.c

    r2435 r5386  
    77  double big,dum,pivinv;
    88 
     9  irow = icol = 0;
     10
    911  ALLOCATE (indxc, int, n);
    1012  ALLOCATE (indxr, int, n);
  • trunk/Ohana/src/gastro/src/gcenter.c

    r2435 r5386  
    2525 
    2626  SearchRadius = NX * SEARCH_RADIUS;
     27  xvect = yvect = NULL;
     28  Nvect = 0;
    2729
    2830  if (PLOTSTUFF) {
    29     Nvect = 0;
    3031    NVECT = N1*N2;
    3132    ALLOCATE (xvect, float, NVECT);
     
    8283  }
    8384
    84 
     85  Xmin = Ymin = 0;
    8586  Fmin = Smin = 1000000.0;
    8687  rot = Rot = ROT_ZERO-dROT*NROT;
     
    131132
    132133    Fmin0 = 1000.0;
     134    Smin0 = Nmin0 = Xmin0 = Ymin0 = 0;
    133135    for (k = 0; k < NPIX*NPIX; k++) {
    134136      n = N[k]; /* 1*/
  • trunk/Ohana/src/gastro/src/gfit.c

    r2435 r5386  
    2626  int Nvect2, NVECT2;
    2727 
     28  Nvect = NVECT = Nvect2 = NVECT2 = 0;
     29  xvect = yvect = xvect2 = yvect2 = NULL;
     30
    2831  if (PLOTSTUFF) {
    29     Nvect2 = 0;
    3032    NVECT2 = MAX(N1, N2);
    31     Nvect = 0;
    3233    NVECT = MAX(N1, N2);
    3334    ALLOCATE (xvect, float, NVECT);
     
    4849  ALLOCATE (Nextra, int, N2);
    4950  bzero (Nextra, sizeof(int) * N2);
     51
     52  dX = dY = N = 0;
    5053
    5154  /* assign and sort list */
  • trunk/Ohana/src/gastro/src/gfitpoly.c

    r2435 r5386  
    100100     on first pass, find the coeffs.
    101101     on next pass, find just the residuals */
     102
     103  dX = dY = d2X = d2Y = N = 0;
    102104  for (last = 0; last < 2; last++) {
    103105    if (last) {
  • trunk/Ohana/src/gastro2/src/gaussj.c

    r2442 r5386  
    77  double big,dum,pivinv;
    88 
     9  irow = icol = 0;
     10
    911  ALLOCATE (indxc, int, n);
    1012  ALLOCATE (indxr, int, n);
  • trunk/Ohana/src/gastro2/src/grid.c

    r2442 r5386  
    2727  YMAX = +0.5*NFIELD*Target[0].header.Naxis[1];
    2828
     29  dX = dY = 0;
    2930  /* make two passes, with grids offset by 0.5 box for the second */
    3031  for (n = 0; n < 2; n++) {
  • trunk/Ohana/src/imclean/src/LoadStarsChad.c

    r3519 r5386  
    2727  /* zero things that will sum */
    2828  for (i = 0; i < HIST_BINS; i++) { Mhist[i] = Shist[i] = 0; }
    29 
     29 
     30  N = 0;
    3031  Nstars = 0;
    3132  NSTARS = 500;
     
    103104  }
    104105  satfound = done = FALSE;
     106  saturate = complete = 0.0;
    105107  for (i = 0; (i < HIST_BINS) && !done; i++) {
    106108    if ((!satfound) && (Mhist[i] > 0)) {
  • trunk/Ohana/src/imclean/src/LoadStarsDophot.c

    r3519 r5386  
    2121  double SMedHist, dMed;
    2222
    23   NMedHist = 0;
     23  N = NMedHist = 0;
    2424  bzero (MedHist, 2002*sizeof(int));
    2525
     
    126126  }
    127127  satfound = done = FALSE;
     128  saturate = complete = 0.0;
    128129  for (i = 0; (i < HIST_BINS) && !done; i++) {
    129130    if ((!satfound) && (Mhist[i] > 0)) {
  • trunk/Ohana/src/imclean/src/LoadStarsSex.c

    r3519 r5386  
    3030
    3131  /* zero things that will sum */
    32   A = A2 = S2 = 0;
     32  N = A = A2 = S2 = 0;
    3333  gotFWHM = FALSE;
    3434  for (i = 0; i < HIST_BINS; i++) { Mhist[i] = Shist[i] = 0; }
     
    117117  }
    118118  satfound = done = FALSE;
     119  saturate = complete = 0.0;
    119120  for (i = 0; (i < HIST_BINS) && !done; i++) {
    120121    if ((!satfound) && (Mhist[i] > 0)) {
  • trunk/Ohana/src/imregister/imphot/subset.c

    r4024 r5386  
    77  int Nsubset, NameSelectLength;
    88  int *index;
     9
     10  NameSelectLength = 0;
    911
    1012  /* allocate space for reference lists */
  • trunk/Ohana/src/imregister/photreg/output.c

    r3606 r5386  
    8181  char *c1, *c2, *code, *photsys, *extname;
    8282  int i;
    83   unsigned int tsecond;
     83  unsigned long tsecond;
    8484
    8585  /* create primary header */
     
    9999   
    100100  /* add current date/time to header */
    101   str_to_time ("now", (unsigned long *)&tsecond);
    102   datestr = sec_to_date (tsecond);
     101  str_to_time ("now", &tsecond);
     102  datestr = sec_to_date ((unsigned int) tsecond);
    103103  fits_modify (&header,  "DATE", "%s", 1, datestr);
    104104  fits_modify (&theader, "DATE", "%s", 1, datestr);
  • trunk/Ohana/src/imregister/src/photcode.c

    r5144 r5386  
    11# include "imregister.h"
    2 static char *version = "photcode $Revision: 3.2 $";
     2static char *version = "photcode $Revision: 3.3 $";
    33
    44int main (int argc, char **argv) {
     
    6161  }
    6262  if (ccd == -1) {
    63     fprintf (stderr, "warning: ccd %s not found in camera config file\n", ccd);
     63    fprintf (stderr, "warning: ccd %d not found in camera config file\n", ccd);
    6464    ccd = 0;
    6565  }
  • trunk/Ohana/src/kapa/graph/DrawFrame.c

    r4769 r5386  
    8181  if (mode == 1) {
    8282    fontname = GetRotFont (&fontsize);
     83    pos = 0;
    8384   
    8485    /* temporarily assume rectilinear axes */
  • trunk/Ohana/src/kapa/graph/DrawLabels.c

    r2473 r5386  
    77  char *fontname;
    88
     9  pos = 0;
    910  fontname = GetRotFont (&size);
    1011  XSetForeground (graphic.display, graphic.gc, graphic.fore);
  • trunk/Ohana/src/kapa/graph/DrawRotString.c

    r4769 r5386  
    2525
    2626  /* apply appropriate offset */
     27  Xoff = Yoff = 0;
    2728  switch (pos) {
    2829  case 0: Xoff =     -dX; Yoff = dY; break;
     
    338339  /* compute string length */
    339340  /* PS fonts are somewhat different scales from bitmap font equivalents */
     341  fscale = 1.0;
    340342  if (!strcmp (currentname, "times")) fscale = 1.07;
    341343  if (!strcmp (currentname, "courier")) fscale = 1.5;
     
    346348 
    347349  /* apply appropriate offset */
     350  Xoff = Yoff = 0;
    348351  switch (pos) {
    349352  case 0: Xoff =     -dX; Yoff = -dY; break;
  • trunk/Ohana/src/kapa/graph/LoadObject.c

    r4772 r5386  
    112112  char *buff;
    113113
     114  buff = NULL;
    114115  Npts = layout[0].objects[N].Npts;
    115116  status = 1;
  • trunk/Ohana/src/kapa/graph/PSFrame.c

    r4769 r5386  
    5555  char string[64], *fontname;
    5656
     57  pos = size = 0;
     58
    5759  if (mode == 1) { size = MAX (0.02, 7.0 / P); }
    5860  if (mode == 0) { size = MAX (0.01, 4.0 / P); }
  • trunk/Ohana/src/kapa/graph/PSLabels.c

    r4769 r5386  
    77  char *fontname;
    88
     9  pos = 0;
    910  fontname = GetRotFont (&size);
    1011  for (i = 0; i < 8; i++) {
  • trunk/Ohana/src/kii/colorbar/DragColorbar.c

    r2466 r5386  
    1717  slope = layout[0].slope;
    1818  start = layout[0].start;
    19   oldfrac_x = 10;
     19  oldfrac_x = oldfrac_y = 10;
    2020 
    2121  while (1) {
  • trunk/Ohana/src/kii/overlay/DrawOverlay.c

    r2466 r5386  
    99  double expand, X0, Y0;
    1010 
     11  expand = 1.0;
    1112  if (layout[0].expand > 0) {
    1213    expand = 1 / (1.0*layout[0].expand);
  • trunk/Ohana/src/kii/overlay/PaintOverlay.c

    r2466 r5386  
    1111  XSetForeground (graphic[0].display, graphic[0].gc, layout[0].overlay[N].color);
    1212 
     13  expand = 1.0;
    1314  if (layout[0].expand > 0) {
    1415    expand = 1 / (1.0*layout[0].expand);
  • trunk/Ohana/src/kii/picture/CursorOps.c

    r2466 r5386  
    55  double expand;
    66
     7  expand = 1.0;
    78  if (layout[0].expand > 0) {
    89    expand = 1 / (1.0*layout[0].expand);
     
    2223
    2324  /* notice that here, expand is the reciprocal of the expand above */
     25  expand = 1.0;
    2426  if (layout[0].expand > 0) {
    2527    expand = abs(layout[0].expand);
  • trunk/Ohana/src/kii/picture/Remap16.c

    r2466 r5386  
    2626  white2 = 0x00ff & (white >> 8);
    2727
     28  expand = expand_in = expand_out = 1.0;
    2829  if (layout[0].expand == 0) /* set up expansions */
    2930    layout[0].expand = 1;
  • trunk/Ohana/src/kii/picture/Remap24.c

    r2466 r5386  
    2727  white3 = 0x0000ff & (white >> 16);
    2828
     29  expand = expand_in = expand_out = 1.0;
    2930  if (layout[0].expand == 0) /* set up expansions */
    3031    layout[0].expand = 1;
  • trunk/Ohana/src/kii/picture/Remap32.c

    r2466 r5386  
    2020  white = layout[0].white;
    2121
     22  expand = expand_in = expand_out = 1.0;
    2223  if (layout[0].expand == 0) /* set up expansions */
    2324    layout[0].expand = 1;
  • trunk/Ohana/src/kii/picture/Remap8.c

    r2466 r5386  
    2020  white = layout[0].white;
    2121
     22  expand = expand_in = expand_out = 1.0;
    2223  if (layout[0].expand == 0) /* set up expansions */
    2324    layout[0].expand = 1;
  • trunk/Ohana/src/kii/setup/DrawBitmap.c

    r2466 r5386  
    1111  int i, j, byte_line, byte, bit, flag;
    1212  unsigned long int black, white;
     13
     14  black = graphic[0].black;
     15  white = graphic[0].white;
    1316
    1417  if (mode == 0) {
  • trunk/Ohana/src/libdvo/src/dvo_image_raw.c

    r5241 r5386  
    4949
    5050  /* get datatype size */
     51  ImageSize = 0;
    5152  if (db[0].format == DVO_FORMAT_INTERNAL)  ImageSize = sizeof(Image);
    5253  if (db[0].format == DVO_FORMAT_LONEOS)    ImageSize = sizeof(ImageLoneos);
  • trunk/Ohana/src/nightd/src/misc.c

    r3466 r5386  
    191191
    192192  done = FALSE;
    193   exit_good = FALSE;
     193  exit_good = exit_stat = FALSE;
    194194  for (i = 0; !done && (i < 10*timeout); i++) {
    195195    Nread = read (rfd[0], buffer, 0x4000);
  • trunk/Ohana/src/opihi/cmd.astro/help/region

    r4688 r5386  
    1010  AIT - aitoff projection (good for the full sky)
    1111  GLS - ?? (also good for the full sky)
     12
     13  optional orientation flags:
     14
     15  -ew : display with East Left (default)
     16  +ew : display with East Right
     17  -ns : display with North Down
     18  +ns : display with North Up (default)
  • trunk/Ohana/src/opihi/cmd.astro/region.c

    r4689 r5386  
    8989  set_variable ("DMAX", Dec + graphmode.ymax);
    9090
     91  set_int_variable ("EAST_RIGHT", !graphmode.flipeast);
     92  set_int_variable ("NORTH_UP", !graphmode.flipnorth);
     93
    9194  graphmode.coords.pc1_1 = (graphmode.flipeast) ? -1 : 1;
    9295  graphmode.coords.pc2_2 = (graphmode.flipnorth) ? -1 : 1;
  • trunk/Ohana/src/opihi/dvo/cmpread.c

    r5144 r5386  
    9393  bzero (vec[0].elements, Nstars*sizeof(float));
    9494
     95  value = 0;
    9596  for (i = 0; i < Nstars; i++) {
    9697    switch (field) {
  • trunk/Ohana/src/relphot/src/gcatalog.c

    r5320 r5386  
    33int gcatalog (Catalog *catalog, int FINAL) {
    44 
    5   char mode;
    6 
    75  if (FINAL) {
    86    catalog[0].catflags = LOAD_AVES | LOAD_MEAS | LOAD_MISS | LOAD_SECF;
  • trunk/Ohana/src/relphot/src/liststats.c

    r4796 r5386  
    2727  int i, ks, ke, Nm;
    2828  double Mo, dMo, M, dM, X2, dS, *chi;
     29
     30  ke = ks = dMo = 0;
    2931
    3032  stats[0].Nmeas = N;
  • trunk/Ohana/src/uniphot/include/uniphot.h

    r5320 r5386  
    7676int           args               PROTO((int argc, char **argv));
    7777void          dumpresult         PROTO(());
    78 Group        *find_image_sgroups PROTO((FITS_DB *db, ImageLink *imlink, int *Nsgroup));
    79 Group        *find_image_tgroups PROTO((FITS_DB *db, ImageLink *imlink, int *Ntgroup));
     78Group        *find_image_sgroups PROTO((FITS_DB *db, ImageLink **imlink, int *Nsgroup));
     79Group        *find_image_tgroups PROTO((FITS_DB *db, ImageLink **imlink, int *Ntgroup));
    8080void          fit_sgroup         PROTO((Group *sgroup, int Nsgroup));
    8181void          fit_tgroup         PROTO((Group *tgroup, int Ntgroup));
  • trunk/Ohana/src/uniphot/src/find_image_sgroups.c

    r4864 r5386  
    11# include "uniphot.h"
    22
    3 Group *find_image_sgroups (FITS_DB *db, ImageLink *imlink, int *Nsgroup) {
     3Group *find_image_sgroups (FITS_DB *db, ImageLink **Imlink, int *Nsgroup) {
    44
    55  int i, j, Nimage, Ngroup, Nentry, NENTRY;
     
    88  Coords coords;
    99  Image *image;
     10  ImageLink *imlink;
    1011
     12  imlink = *Imlink;
    1113  image = fits_table_get_Image (&db[0].ftable, &Nimage, &db[0].swapped);
    1214
  • trunk/Ohana/src/uniphot/src/find_image_tgroups.c

    r4864 r5386  
    11# include "uniphot.h"
    22
    3 Group *find_image_tgroups (FITS_DB *db, ImageLink *imlink, int *Ntgroup) {
     3Group *find_image_tgroups (FITS_DB *db, ImageLink **Imlink, int *Ntgroup) {
    44
    55  char *start, *stop;
     
    88  Group *group;
    99  Image *image;
     10  ImageLink *imlink;
    1011
    1112  image = fits_table_get_Image (&db[0].ftable, &Nimage, &db[0].swapped);
     13  ALLOCATE (imlink, ImageLink, Nimage);
    1214
    1315  /* sort time list (use only valid images?) */
     
    7577    group[i].Nimage = Nentry;
    7678  }
     79  *Imlink = imlink;
    7780  *Ntgroup = Ngroup;
    7881  return (group);
  • trunk/Ohana/src/uniphot/src/liststats.c

    r2492 r5386  
    2727  int i, ks, ke, Nm;
    2828  double Mo, dMo, M, dM, X2, dS, *chi;
     29
     30  ke = ks = dMo = 0;
    2931
    3032  stats[0].Nmeas = N;
  • trunk/Ohana/src/uniphot/src/uniphot.c

    r4864 r5386  
    33int main (int argc, char **argv) {
    44
    5   int i, Nimage, Ntgroup, Nsgroup;
     5  int i, Ntgroup, Nsgroup;
    66  Group *tgroup, *sgroup;
    77  ImageLink *imlinks;
     
    2020  subset_images (&db);
    2121
    22   ALLOCATE (imlinks, ImageLink, Nimage);
    23   tgroup = find_image_tgroups (&db, imlinks, &Ntgroup);
    24   sgroup = find_image_sgroups (&db, imlinks, &Nsgroup);
     22  tgroup = find_image_tgroups (&db, &imlinks, &Ntgroup);
     23  sgroup = find_image_sgroups (&db, &imlinks, &Nsgroup);
    2524
    2625  /* determine fit values */
Note: See TracChangeset for help on using the changeset viewer.