Changeset 27924
- Timestamp:
- May 11, 2010, 5:39:56 PM (16 years ago)
- Location:
- branches/eam_branches/psModules.20100506/src/objects
- Files:
-
- 1 added
- 7 edited
-
Makefile.am (modified) (1 diff)
-
pmSource.c (modified) (2 diffs)
-
pmSource.h (modified) (1 diff)
-
pmSourceExtendedPars.c (modified) (1 diff)
-
pmSourceExtendedPars.h (modified) (2 diffs)
-
pmSourceIO.c (modified) (5 diffs)
-
pmSourceIO.h (modified) (2 diffs)
-
pmSourceIO_CMF_PS1_SV1.c (added)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/psModules.20100506/src/objects/Makefile.am
r27672 r27924 43 43 pmSourceIO_CMF_PS1_V1.c \ 44 44 pmSourceIO_CMF_PS1_V2.c \ 45 pmSourceIO_CMF_PS1_SV1.c \ 45 46 pmSourceIO_CMF_PS1_DV1.c \ 46 47 pmSourceIO_MatchedRefs.c \ -
branches/eam_branches/psModules.20100506/src/objects/pmSource.c
r27657 r27924 54 54 psFree(tmp->moments); 55 55 psFree(tmp->diffStats); 56 psFree(tmp->radial); 56 57 psFree(tmp->blends); 57 58 psTrace("psModules.objects", 10, "---- end ----\n"); … … 116 117 source->extpars = NULL; 117 118 source->diffStats = NULL; 119 source->radial = NULL; 118 120 119 121 source->region = psRegionSet(NAN, NAN, NAN, NAN); -
branches/eam_branches/psModules.20100506/src/objects/pmSource.h
r27657 r27924 91 91 pmSourceExtendedPars *extpars; ///< extended source parameters 92 92 pmSourceDiffStats *diffStats; ///< extra parameters for difference detections 93 pmSourceRadialApertures *radial; ///< radial flux in circular apertures 93 94 int imageID; 94 95 }; -
branches/eam_branches/psModules.20100506/src/objects/pmSourceExtendedPars.c
r27818 r27924 65 65 } 66 66 67 // pmSourceRadialApertures carries the raw radial flux information, including angular bins 68 static void pmSourceRadialAperturesFree(pmSourceRadialApertures *radial) 69 { 70 if (!radial) return; 71 psFree(radial->flux); 72 psFree(radial->fill); 73 } 74 75 pmSourceRadialApertures *pmSourceRadialAperturesAlloc() 76 { 77 pmSourceRadialApertures *radial = (pmSourceRadialApertures *)psAlloc(sizeof(pmSourceRadialApertures)); 78 psMemSetDeallocator(radial, (psFreeFunc) pmSourceRadialAperturesFree); 79 80 radial->flux = NULL; 81 radial->fill = NULL; 82 return radial; 83 } 84 85 bool psMemCheckSourceRadialApertures(psPtr ptr) 86 { 87 PS_ASSERT_PTR(ptr, false); 88 return ( psMemGetDeallocator(ptr) == (psFreeFunc) pmSourceRadialAperturesFree); 89 } 90 67 91 // pmSourceEllipticalFlux carries the elliptical renormalized radial flux info 68 92 static void pmSourceEllipticalFluxFree(pmSourceEllipticalFlux *flux) -
branches/eam_branches/psModules.20100506/src/objects/pmSourceExtendedPars.h
r27818 r27924 20 20 psVector *isophotalRadii; // isophotal radius for the above angles 21 21 } pmSourceRadialFlux; 22 23 typedef struct { 24 psVector *flux; // fluxes measured at above radii 25 psVector *fill; // angles corresponding to above radial profiles 26 } pmSourceRadialApertures; 22 27 23 28 typedef struct { … … 62 67 bool psMemCheckSourceRadialFlux(psPtr ptr); 63 68 69 pmSourceRadialApertures *pmSourceRadialAperturesAlloc(); 70 bool psMemCheckSourceRadialApertures(psPtr ptr); 71 64 72 pmSourceEllipticalFlux *pmSourceEllipticalFluxAlloc(); 65 73 bool psMemCheckSourceEllipticalFlux(psPtr ptr); -
branches/eam_branches/psModules.20100506/src/objects/pmSourceIO.c
r27818 r27924 539 539 status &= pmSourcesWrite_CMF_PS1_V2 (file->fits, readout, sources, file->header, outhead, dataname); 540 540 } 541 if (!strcmp (exttype, "PS1_SV1")) { 542 status &= pmSourcesWrite_CMF_PS1_SV1 (file->fits, readout, sources, file->header, outhead, dataname, recipe); 543 } 541 544 if (!strcmp (exttype, "PS1_DV1")) { 542 545 status &= pmSourcesWrite_CMF_PS1_DV1 (file->fits, readout, sources, file->header, outhead, dataname); … … 556 559 status &= pmSourcesWrite_CMF_PS1_V2_XSRC (file->fits, readout, sources, file->header, xsrcname, recipe); 557 560 } 561 if (!strcmp (exttype, "PS1_SV1")) { 562 status &= pmSourcesWrite_CMF_PS1_SV1_XSRC (file->fits, readout, sources, file->header, xsrcname, recipe); 563 } 558 564 if (!strcmp (exttype, "PS1_DV1")) { 559 565 status &= pmSourcesWrite_CMF_PS1_DV1_XSRC (file->fits, readout, sources, file->header, xsrcname, recipe); … … 573 579 status &= pmSourcesWrite_CMF_PS1_V2_XFIT (file->fits, readout, sources, xfitname); 574 580 } 581 if (!strcmp (exttype, "PS1_SV1")) { 582 status &= pmSourcesWrite_CMF_PS1_SV1_XFIT (file->fits, readout, sources, xfitname); 583 } 575 584 if (!strcmp (exttype, "PS1_DV1")) { 576 585 status &= pmSourcesWrite_CMF_PS1_DV1_XFIT (file->fits, readout, sources, xfitname); … … 981 990 // we need to find the corresponding table EXTNAME. 982 991 // first check the header 983 char *extdata = psMetadataLookupStr ( NULL, hdu->header, "EXTDATA");992 char *extdata = psMetadataLookupStr (&status, hdu->header, "EXTDATA"); 984 993 if (extdata) { 985 994 // if EXTDATA is defined in the header, use that value for 'dataname' … … 1023 1032 if (!strcmp (exttype, "PS1_V2")) { 1024 1033 sources = pmSourcesRead_CMF_PS1_V2 (file->fits, hdu->header); 1034 } 1035 if (!strcmp (exttype, "PS1_SV1")) { 1036 sources = pmSourcesRead_CMF_PS1_SV1 (file->fits, hdu->header); 1025 1037 } 1026 1038 if (!strcmp (exttype, "PS1_DV1")) { -
branches/eam_branches/psModules.20100506/src/objects/pmSourceIO.h
r27818 r27924 43 43 bool pmSourcesWrite_CMF_PS1_V2_XFIT (psFits *fits, pmReadout *readout, psArray *sources, char *extname); 44 44 45 bool pmSourcesWrite_CMF_PS1_SV1 (psFits *fits, pmReadout *readout, psArray *sources, psMetadata *imageHeader, psMetadata *tableHeader, char *extname, psMetadata *recipe); 46 bool pmSourcesWrite_CMF_PS1_SV1_XSRC (psFits *fits, pmReadout *readout, psArray *sources, psMetadata *imageHeader, char *extname, psMetadata *recipe); 47 bool pmSourcesWrite_CMF_PS1_SV1_XFIT (psFits *fits, pmReadout *readout, psArray *sources, char *extname); 48 45 49 bool pmSourcesWrite_CMF_PS1_DV1 (psFits *fits, pmReadout *readout, psArray *sources, psMetadata *imageHeader, psMetadata *tableHeader, char *extname); 46 50 bool pmSourcesWrite_CMF_PS1_DV1_XSRC (psFits *fits, pmReadout *readout, psArray *sources, psMetadata *imageHeader, char *extname, psMetadata *recipe); … … 57 61 psArray *pmSourcesRead_CMF_PS1_V1 (psFits *fits, psMetadata *header); 58 62 psArray *pmSourcesRead_CMF_PS1_V2 (psFits *fits, psMetadata *header); 63 psArray *pmSourcesRead_CMF_PS1_SV1 (psFits *fits, psMetadata *header); 59 64 psArray *pmSourcesRead_CMF_PS1_DV1 (psFits *fits, psMetadata *header); 60 65
Note:
See TracChangeset
for help on using the changeset viewer.
