00001
00002
00003
00004
00005
00006
00007 #include <stdio.h>
00008 #include <math.h>
00009 #include "imcore.h"
00010 #include "util.h"
00011 #include "../vircam_fits.h"
00012
00013 extern void tabinit_4(ap_t *ap) {
00014 long npts,i;
00015 cpl_binary *opm;
00016
00017
00018
00019 tab = NULL;
00020 npts = (ap->lsiz)*(ap->csiz);
00021 ap->opmask = cpl_mask_new(ap->lsiz,ap->csiz);
00022 opm = cpl_mask_get_data(ap->opmask);
00023 for (i = 0; i < npts; i++)
00024 opm[i] = 0;
00025
00026
00027
00028 imcore_xcol = -1;
00029 imcore_ycol = -1;
00030
00031 }
00032
00033 extern int do_seeing_4(ap_t *ap) {
00034
00035
00036
00037 ap->fwhm = 0.0;
00038 return(VIR_OK);
00039 }
00040
00041
00042 extern int process_results_4(ap_t *ap) {
00043 int i,j,np;
00044 long nx;
00045 plstruct *plarray;
00046 cpl_binary *opm;
00047
00048
00049
00050 opm = cpl_mask_get_data(ap->opmask);
00051 plarray = ap->plarray;
00052 np = ap->npl_pix;
00053 nx = ap->lsiz;
00054 for (i = 0; i < np; i++) {
00055 j = nx*(plarray[i].y - 1) + plarray[i].x - 1;
00056 opm[j] = 1;
00057 }
00058
00059
00060
00061 return(VIR_OK);
00062 }
00063
00064 extern int tabclose_4(ap_t *ap) {
00065
00066 cpl_image_reject_from_mask(ap->inframe,ap->opmask);
00067 cpl_mask_delete(ap->opmask);
00068 return(VIR_OK);
00069 }
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087