Changeset 34749 for trunk/Ohana/src/relastro
- Timestamp:
- Nov 30, 2012, 10:06:05 AM (14 years ago)
- Location:
- trunk/Ohana/src/relastro/src
- Files:
-
- 4 edited
-
ConfigInit.c (modified) (3 diffs)
-
ImageOps.c (modified) (1 diff)
-
UpdateObjects.c (modified) (1 diff)
-
args.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/relastro/src/ConfigInit.c
r33963 r34749 5 5 char *config, *file; 6 6 char CatdirPhotcodeFile[256]; 7 char MasterPhotcodeFile[256];8 7 struct stat filestat; 9 8 int status; … … 46 45 ScanConfig(config, "CATMODE", "%s", 0, CATMODE); 47 46 ScanConfig(config, "CATFORMAT", "%s", 0, CATFORMAT); 48 ScanConfig(config, "PHOTCODE_FILE", "%s", 0, MasterPhotcodeFile);49 47 50 48 // Defaults for WHERE_A are established in db_utils.c: intializeConstraints … … 73 71 /* update master photcode table if not defined */ 74 72 sprintf (CatdirPhotcodeFile, "%s/Photcodes.dat", CATDIR); 75 if (!LoadPhotcodes (CatdirPhotcodeFile, MasterPhotcodeFile, TRUE)) {76 fprintf (stderr, "error loading photcode table %s or master file %s\n", CatdirPhotcodeFile, MasterPhotcodeFile);73 if (!LoadPhotcodes (CatdirPhotcodeFile, NULL, FALSE)) { 74 fprintf (stderr, "error loading photcode table %s\n", CatdirPhotcodeFile); 77 75 exit (1); 78 76 } -
trunk/Ohana/src/relastro/src/ImageOps.c
r34088 r34749 174 174 for (i = 0; i < Ncatalog; i++) { 175 175 for (j = 0; j < catalog[i].Nmeasure; j++) { 176 // XXX : update to optionally restrict by photcode equiv a la relphot 177 // ecode = GetPhotcodeEquivCodebyCode (catalog[i].measure[j].photcode); 178 // if (photcode[0].code != ecode) continue; 176 if (NphotcodesSkip > 0) { 177 int k; 178 int found = FALSE; 179 for (k = 0; (k < NphotcodesSkip) && !found; k++) { 180 if (photcodesSkip[k][0].code == catalog[i].measure[j].photcode) found = TRUE; 181 if (photcodesSkip[k][0].code == GetPhotcodeEquivCodebyCode(catalog[i].measure[j].photcode)) found = TRUE; 182 } 183 if (found) continue; 184 } 179 185 matchImage (catalog, j, i, MATCHCAT); 180 186 } -
trunk/Ohana/src/relastro/src/UpdateObjects.c
r34576 r34749 112 112 if (XVERB) { 113 113 char *date = ohana_sec_to_date (measure[k].t); 114 fprintf (stderr, OFF_T_FMT" %f %f %s : 0x%08x : 0x%08x\n", k, measure[k].dR, measure[k].dD, date, measure[k].dbFlags, measureBig[k].dbFlags); 114 int dbFlagsBig = measureBig ? measureBig[k].dbFlags : 0; 115 fprintf (stderr, OFF_T_FMT" %f %f %s : 0x%08x : 0x%08x\n", k, measure[k].dR, measure[k].dD, date, measure[k].dbFlags, dbFlagsBig); 115 116 free (date); 116 117 } -
trunk/Ohana/src/relastro/src/args.c
r33963 r34749 237 237 } 238 238 239 PHOTCODE_SKIP_LIST = NULL;239 PHOTCODE_SKIP_LIST = strcreate("SCOS.103a.E,SCOS.4414.OG590,SCOS.4415.OG590,SCOS.IIIaF.OG590,SCOS.IIIaF.RG610,SCOS.IIIaF.RG630,SCOS.IIIaJ.GG385,SCOS.IIIaJ.GG395,SCOS.IVN.RG715,SCOS.IVN.RG9"); 240 240 if ((N = get_argument (argc, argv, "-photcode"))) { 241 241 remove_argument (N, &argc, argv); 242 PHOTCODE_SKIP_LIST = strcreate(argv[N]); 242 char *tmp1 = strcreate(argv[N]); 243 244 int Ntotal = strlen(tmp1) + strlen(PHOTCODE_SKIP_LIST) + 5; 245 246 char *tmp2 = NULL; 247 ALLOCATE (tmp2, char, Ntotal); 248 snprintf (tmp2, Ntotal, "%s,%s", PHOTCODE_SKIP_LIST, tmp1); 249 250 free (tmp1); 251 free (PHOTCODE_SKIP_LIST); 252 253 PHOTCODE_SKIP_LIST = tmp2; 243 254 remove_argument (N, &argc, argv); 244 255 }
Note:
See TracChangeset
for help on using the changeset viewer.
