Changeset 36833 for trunk/Ohana/src/libdvo
- Timestamp:
- Jun 7, 2014, 6:33:11 AM (12 years ago)
- Location:
- trunk/Ohana/src/libdvo
- Files:
-
- 12 edited
-
include/dvo.h (modified) (2 diffs)
-
include/dvodb.h (modified) (2 diffs)
-
src/dbExtractAverages.c (modified) (1 diff)
-
src/dbExtractImages.c (modified) (7 diffs)
-
src/dbFields.c (modified) (2 diffs)
-
src/dvo_catalog.c (modified) (1 diff)
-
src/dvo_convert_PS1_DEV_2.c (modified) (2 diffs)
-
src/dvo_convert_PS1_V1.c (modified) (2 diffs)
-
src/dvo_convert_PS1_V2.c (modified) (4 diffs)
-
src/dvo_convert_PS1_V3.c (modified) (4 diffs)
-
src/dvo_convert_PS1_V4.c (modified) (5 diffs)
-
src/skyregion_io.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/libdvo/include/dvo.h
r36630 r36833 171 171 ID_STAR_USE_PAR = 0x00200000, // parallax used (not AVE or PM) 172 172 ID_STAR_NO_ASTROM = 0x00400000, // mean astrometry could not be measured 173 ID_STAR_BAD_PM = 0x00800000, // mean astrometry could not be measured 173 174 ID_OBJ_EXT = 0x01000000, // extended in our data (eg, PS) 174 175 ID_OBJ_EXT_ALT = 0x02000000, // extended in external data (eg, 2MASS) … … 481 482 uint32_t measureOffset; // offset to first psf measurement 482 483 uint32_t missingOffset; // offset to first missing obs 483 uint32_t extendOffset;// offset to first extended measurement484 float refColor; // offset to first extended measurement 484 485 uint32_t flags; // average object flags (star; ghost; etc) 485 486 uint32_t photFlagsUpper; // upper bit of 2 bit summary of per-measure photflags -
trunk/Ohana/src/libdvo/include/dvodb.h
r36630 r36833 222 222 AVE_EXTID_HI, 223 223 AVE_EXTID_LO, 224 AVE_REF_COLOR, 224 225 }; 225 226 … … 289 290 IMAGE_NFIT_ASTROM, 290 291 IMAGE_NLINK_PHOTOM, 291 IMAGE_NLINK_ASTROM 292 IMAGE_NLINK_ASTROM, 293 IMAGE_REF_COLOR 292 294 }; 293 295 -
trunk/Ohana/src/libdvo/src/dbExtractAverages.c
r36630 r36833 161 161 case AVE_STARGAL: 162 162 value.Flt = average[0].stargal; 163 break; 164 case AVE_REF_COLOR: 165 value.Flt = average[0].refColor; 163 166 break; 164 167 -
trunk/Ohana/src/libdvo/src/dbExtractImages.c
r35102 r36833 69 69 if (!haveCelestial) { 70 70 if (!FindMosaicForImage (image, Nimage, N)) return value; 71 x = 0.5*image[N].NX; 72 y = 0.5*image[N].NY; 71 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 72 x = 0.0; 73 y = 0.0; 74 } else { 75 x = 0.5*image[N].NX; 76 y = 0.5*image[N].NY; 77 } 73 78 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 74 79 haveCelestial = TRUE; … … 79 84 if (!haveCelestial) { 80 85 if (!FindMosaicForImage (image, Nimage, N)) return value; 81 x = 0.5*image[N].NX; 82 y = 0.5*image[N].NY; 86 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 87 x = 0.0; 88 y = 0.0; 89 } else { 90 x = 0.5*image[N].NX; 91 y = 0.5*image[N].NY; 92 } 83 93 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 84 94 haveCelestial = TRUE; … … 90 100 if (!haveCelestial) { 91 101 if (!FindMosaicForImage (image, Nimage, N)) return value; 92 x = 0.5*image[N].NX; 93 y = 0.5*image[N].NY; 102 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 103 x = 0.0; 104 y = 0.0; 105 } else { 106 x = 0.5*image[N].NX; 107 y = 0.5*image[N].NY; 108 } 94 109 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 95 110 haveCelestial = TRUE; … … 104 119 if (!haveCelestial) { 105 120 if (!FindMosaicForImage (image, Nimage, N)) return value; 106 x = 0.5*image[N].NX; 107 y = 0.5*image[N].NY; 121 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 122 x = 0.0; 123 y = 0.0; 124 } else { 125 x = 0.5*image[N].NX; 126 y = 0.5*image[N].NY; 127 } 108 128 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 109 129 haveCelestial = TRUE; … … 118 138 if (!haveCelestial) { 119 139 if (!FindMosaicForImage (image, Nimage, N)) return value; 120 x = 0.5*image[N].NX; 121 y = 0.5*image[N].NY; 140 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 141 x = 0.0; 142 y = 0.0; 143 } else { 144 x = 0.5*image[N].NX; 145 y = 0.5*image[N].NY; 146 } 122 147 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 123 148 haveCelestial = TRUE; … … 132 157 if (!haveCelestial) { 133 158 if (!FindMosaicForImage (image, Nimage, N)) return value; 134 x = 0.5*image[N].NX; 135 y = 0.5*image[N].NY; 159 if (!strcmp(&image[N].coords.ctype[4], "-DIS")) { 160 x = 0.0; 161 y = 0.0; 162 } else { 163 x = 0.5*image[N].NX; 164 y = 0.5*image[N].NY; 165 } 136 166 XY_to_RD (&RAo, &DECo, x, y, &image[N].coords); 137 167 haveCelestial = TRUE; … … 344 374 value.Int = image[N].nLinkAstrom; 345 375 break; 376 377 case IMAGE_REF_COLOR: 378 value.Flt = image[N].refColor; 379 break; 346 380 } 347 381 return (value); -
trunk/Ohana/src/libdvo/src/dbFields.c
r36630 r36833 381 381 if (!strcasecmp (fieldName, "EXTID_HI")) ESCAPE (AVE_EXTID_HI, MAG_NONE, OPIHI_INT); 382 382 if (!strcasecmp (fieldName, "EXTID_LO")) ESCAPE (AVE_EXTID_LO, MAG_NONE, OPIHI_INT); 383 if (!strcasecmp (fieldName, "REF_COLOR")) ESCAPE (AVE_REF_COLOR, MAG_NONE, OPIHI_FLT); 383 384 384 385 // check for code:mode in photcode name … … 522 523 if (!strcasecmp (fieldName, "UCDIST")) ESCAPE (IMAGE_UBERCAL_DIST,MAG_NONE, OPIHI_INT); 523 524 524 if (!strcasecmp (fieldName, "NFIT_PHOTOM")) ESCAPE (IMAGE_NFIT_PHOTOM,MAG_NONE, OPIHI_INT); 525 if (!strcasecmp (fieldName, "NFIT_ASTROM")) ESCAPE (IMAGE_NFIT_ASTROM,MAG_NONE, OPIHI_INT); 526 if (!strcasecmp (fieldName, "NLINK_PHOTOM")) ESCAPE (IMAGE_NLINK_PHOTOM,MAG_NONE, OPIHI_INT); 527 if (!strcasecmp (fieldName, "NLINK_ASTROM")) ESCAPE (IMAGE_NLINK_ASTROM,MAG_NONE, OPIHI_INT); 525 if (!strcasecmp (fieldName, "NFIT_PHOTOM")) ESCAPE (IMAGE_NFIT_PHOTOM, MAG_NONE, OPIHI_INT); 526 if (!strcasecmp (fieldName, "NFIT_ASTROM")) ESCAPE (IMAGE_NFIT_ASTROM, MAG_NONE, OPIHI_INT); 527 if (!strcasecmp (fieldName, "NLINK_PHOTOM")) ESCAPE (IMAGE_NLINK_PHOTOM, MAG_NONE, OPIHI_INT); 528 if (!strcasecmp (fieldName, "NLINK_ASTROM")) ESCAPE (IMAGE_NLINK_ASTROM, MAG_NONE, OPIHI_INT); 529 if (!strcasecmp (fieldName, "REF_COLOR")) ESCAPE (IMAGE_REF_COLOR, MAG_NONE, OPIHI_FLT); 528 530 529 531 // for words that don't parse, try a photcode -
trunk/Ohana/src/libdvo/src/dvo_catalog.c
r36630 r36833 100 100 average->measureOffset = -1; 101 101 average->missingOffset = -1; 102 average-> extendOffset = -1;102 average->refColor = NAN; 103 103 104 104 average->flags = 0; -
trunk/Ohana/src/libdvo/src/dvo_convert_PS1_DEV_2.c
r35162 r36833 119 119 out[i].measureOffset = in[i].measureOffset; 120 120 out[i].missingOffset = in[i].missingOffset; 121 out[i]. extendOffset = in[i].extendOffset;121 out[i].refColor = in[i].refColor; 122 122 out[i].objID = in[i].objID; 123 123 out[i].catID = in[i].catID; … … 153 153 out[i].measureOffset = in[i].measureOffset; 154 154 out[i].missingOffset = in[i].missingOffset; 155 out[i]. extendOffset = in[i].extendOffset;155 out[i].refColor = in[i].refColor; 156 156 out[i].objID = in[i].objID; 157 157 out[i].catID = in[i].catID; -
trunk/Ohana/src/libdvo/src/dvo_convert_PS1_V1.c
r35162 r36833 140 140 out[i].measureOffset = in[i].measureOffset; 141 141 out[i].missingOffset = in[i].missingOffset; 142 out[i]. extendOffset = in[i].extendOffset;142 out[i].refColor = in[i].refColor; 143 143 out[i].flags = in[i].flags; 144 144 out[i].objID = in[i].objID; … … 175 175 out[i].measureOffset = in[i].measureOffset; 176 176 out[i].missingOffset = in[i].missingOffset; 177 out[i]. extendOffset = in[i].extendOffset;177 out[i].refColor = in[i].refColor; 178 178 out[i].flags = in[i].flags; 179 179 out[i].objID = in[i].objID; -
trunk/Ohana/src/libdvo/src/dvo_convert_PS1_V2.c
r35162 r36833 145 145 out[i].measureOffset = in[i].measureOffset; 146 146 out[i].missingOffset = in[i].missingOffset; 147 out[i]. extendOffset = in[i].extendOffset;147 out[i].refColor = in[i].refColor; 148 148 out[i].flags = in[i].flags; 149 149 out[i].objID = in[i].objID; … … 184 184 out[i].measureOffset = in[i].measureOffset; 185 185 out[i].missingOffset = in[i].missingOffset; 186 out[i]. extendOffset = in[i].extendOffset;186 out[i].refColor = in[i].refColor; 187 187 out[i].flags = in[i].flags; 188 188 out[i].objID = in[i].objID; … … 269 269 out[i].DECo = in[i].DECo; 270 270 out[i].Radius = in[i].Radius; 271 out[i].refColor = in[i].refColor; 271 272 272 273 out[i].detection_limit = in[i].detection_limit; … … 331 332 out[i].DECo = in[i].DECo; 332 333 out[i].Radius = in[i].Radius; 334 out[i].refColor = in[i].refColor; 333 335 334 336 out[i].detection_limit = in[i].detection_limit; -
trunk/Ohana/src/libdvo/src/dvo_convert_PS1_V3.c
r35162 r36833 145 145 out[i].measureOffset = in[i].measureOffset; 146 146 out[i].missingOffset = in[i].missingOffset; 147 out[i]. extendOffset = in[i].extendOffset;147 out[i].refColor = in[i].refColor; 148 148 out[i].flags = in[i].flags; 149 149 out[i].photFlagsUpper = in[i].photFlagsUpper; … … 186 186 out[i].measureOffset = in[i].measureOffset; 187 187 out[i].missingOffset = in[i].missingOffset; 188 out[i]. extendOffset = in[i].extendOffset;188 out[i].refColor = in[i].refColor; 189 189 out[i].flags = in[i].flags; 190 190 out[i].photFlagsUpper = in[i].photFlagsUpper; … … 279 279 out[i].DECo = in[i].DECo; 280 280 out[i].Radius = in[i].Radius; 281 out[i].refColor = in[i].refColor; 281 282 282 283 out[i].detection_limit = in[i].detection_limit; … … 341 342 out[i].DECo = in[i].DECo; 342 343 out[i].Radius = in[i].Radius; 344 out[i].refColor = in[i].refColor; 343 345 344 346 out[i].detection_limit = in[i].detection_limit; -
trunk/Ohana/src/libdvo/src/dvo_convert_PS1_V4.c
r36630 r36833 166 166 out[i].measureOffset = in[i].measureOffset; 167 167 out[i].missingOffset = in[i].missingOffset; 168 out[i]. extendOffset = in[i].extendOffset;168 out[i].refColor = in[i].refColor; 169 169 out[i].flags = in[i].flags; 170 170 out[i].photFlagsUpper = in[i].photFlagsUpper; … … 210 210 out[i].measureOffset = in[i].measureOffset; 211 211 out[i].missingOffset = in[i].missingOffset; 212 out[i]. extendOffset = in[i].extendOffset;212 out[i].refColor = in[i].refColor; 213 213 out[i].flags = in[i].flags; 214 214 out[i].photFlagsUpper = in[i].photFlagsUpper; … … 317 317 out[i].DECo = in[i].DECo; 318 318 out[i].Radius = in[i].Radius; 319 out[i].refColor = in[i].refColor; 319 320 320 321 out[i].detection_limit = in[i].detection_limit; … … 379 380 out[i].DECo = in[i].DECo; 380 381 out[i].Radius = in[i].Radius; 382 out[i].refColor = in[i].refColor; 381 383 382 384 out[i].detection_limit = in[i].detection_limit; … … 680 682 out[i].measureOffset = in[i].measureOffset; 681 683 out[i].missingOffset = in[i].missingOffset; 682 out[i]. extendOffset = in[i].extendOffset;684 out[i].refColor = in[i].refColor; 683 685 out[i].flags = in[i].flags; 684 686 out[i].photFlagsUpper = in[i].photFlagsUpper; -
trunk/Ohana/src/libdvo/src/skyregion_io.c
r33649 r36833 78 78 gfits_free_matrix (&matrix); 79 79 gfits_free_header (&theader); 80 fclose (f); 80 81 81 82 return (skytable);
Note:
See TracChangeset
for help on using the changeset viewer.
