/* FILE: phot_calc.c * PURPOSE: Do Quick&Dirty photometry calculations. * AUTHOR: Kenneth J. Mighell (mighell@noao.edu) * LANGUAGE: ANSI C * DATE: 2001JUL03 * COPYRIGHT: (C) 2001 Assoc. of Universities for Research in Astronomy Inc. */ #include "mx.h" #include "qdphot.h" int qdphot5_PhotS_Calc_f5 ( qdphot5_ImageS *Image, qdphot5_PhotS *Phot, double x1cood_p, double y1cood_p, int id_p ){ char mxfunc[] = "qdphot5_PhotS_Calc_f5"; int status = -1; /* initialization */ status = qdphot5_PhotS_CalcInit_f5 ( Image, Phot, x1cood_p, y1cood_p, id_p); if (status) goto bye; /* aperture background */ status = qdphot5_PhotS_CalcBkg_f2( Image, Phot ); if (status) goto bye; /* aperture signal */ status = qdphot5_PhotS_CalcSgnl_f2( Image, Phot ); if (status) goto bye; /* stellar magnitude */ status = qdphot5_PhotS_CalcMag_f2( Image, Phot ); if (status) goto bye; /* check results */ status = qdphot5_PhotS_CalcCheck_f2( Image, Phot ); if (status) goto bye; bye: if (status==0) { Phot->ok = MX_TRUE; } else { Phot->ok = MX_FALSE; } return( status ); } /* end-of-file */