Changeset 36817
- Timestamp:
- Jun 5, 2014, 4:04:26 PM (12 years ago)
- Location:
- branches/eam_branches/ipp-20140423/psModules/src
- Files:
-
- 4 edited
-
astrom/pmAstrometryModel.c (modified) (2 diffs)
-
astrom/pmAstrometryModel.h (modified) (1 diff)
-
concepts/pmConcepts.c (modified) (1 diff)
-
concepts/pmConcepts.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20140423/psModules/src/astrom/pmAstrometryModel.c
r26260 r36817 39 39 #include "pmFPAExtent.h" 40 40 #include "pmFPAfileFitsIO.h" 41 #include "pmConcepts.h" 41 42 #include "pmAstrometryWCS.h" 42 43 #include "pmAstrometryUtils.h" … … 452 453 } 453 454 454 int pmConceptsChipNumberFromName (pmFPA *fpa, char *name) {455 456 for (int i = 0; i < fpa->chips->n; i++) {457 pmChip *chip = fpa->chips->data[i];458 if (!chip) continue;459 char *thisone = psMetadataLookupStr (NULL, chip->concepts, "CHIP.NAME");460 if (!thisone) continue;461 if (!strcmp (name, thisone)) return (i);462 }463 return -1;464 }465 466 pmChip *pmConceptsChipFromName (pmFPA *fpa, char *name) {467 468 for (int i = 0; i < fpa->chips->n; i++) {469 pmChip *chip = fpa->chips->data[i];470 if (!chip) continue;471 char *thisone = psMetadataLookupStr (NULL, chip->concepts, "CHIP.NAME");472 if (!thisone) continue;473 if (!strcmp (name, thisone)) return (chip);474 }475 return NULL;476 }477 478 455 // first layer converts Chip to Focal Plane 479 456 bool pmAstromModelReadChips (pmFPAfile *file) { -
branches/eam_branches/ipp-20140423/psModules/src/astrom/pmAstrometryModel.h
r18601 r36817 27 27 bool pmAstromModelWriteChips (pmFPAfile *file); 28 28 29 int pmConceptsChipNumberFromName (pmFPA *fpa, char *name);30 pmChip *pmConceptsChipFromName (pmFPA *fpa, char *name);31 32 29 bool pmAstromModelReadForView (const pmFPAview *view, pmFPAfile *file, const pmConfig *config); 33 30 bool pmAstromModelReadFPA (pmFPAfile *file); -
branches/eam_branches/ipp-20140423/psModules/src/concepts/pmConcepts.c
r30049 r36817 578 578 } 579 579 580 int pmConceptsChipNumberFromName (pmFPA *fpa, char *name) { 581 582 for (int i = 0; i < fpa->chips->n; i++) { 583 pmChip *chip = fpa->chips->data[i]; 584 if (!chip) continue; 585 char *thisone = psMetadataLookupStr (NULL, chip->concepts, "CHIP.NAME"); 586 if (!thisone) continue; 587 if (!strcmp (name, thisone)) return (i); 588 } 589 return -1; 590 } 591 592 pmChip *pmConceptsChipFromName (pmFPA *fpa, char *name) { 593 594 for (int i = 0; i < fpa->chips->n; i++) { 595 pmChip *chip = fpa->chips->data[i]; 596 if (!chip) continue; 597 char *thisone = psMetadataLookupStr (NULL, chip->concepts, "CHIP.NAME"); 598 if (!thisone) continue; 599 if (!strcmp (name, thisone)) return (chip); 600 } 601 return NULL; 602 } 603 -
branches/eam_branches/ipp-20140423/psModules/src/concepts/pmConcepts.h
r22699 r36817 161 161 ); 162 162 163 // some utility functions: 164 int pmConceptsChipNumberFromName (pmFPA *fpa, char *name); 165 pmChip *pmConceptsChipFromName (pmFPA *fpa, char *name); 166 163 167 /// @} 164 168 #endif
Note:
See TracChangeset
for help on using the changeset viewer.
