/* @(#)tbfhand.c 17.1.1.1 (ESO-DMD) 01/25/02 17:50:16 */ /*=========================================================================== Copyright (C) 1995 European Southern Observatory (ESO) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA. Correspondence concerning ESO-MIDAS should be addressed as follows: Internet e-mail: midas@eso.org Postal address: European Southern Observatory Data Management Division Karl-Schwarzschild-Strasse 2 D 85748 Garching bei Muenchen GERMANY 010802 last modif ===========================================================================*/ #include #include #include #include #include #include #include #include #define MAXBIN 1024 #define NM 32 #define NT 5 char *osmmget() ; main() { int dummy,i,j,k,l ; int status,tid,nrow,kcol,nocat,otid,no,ormf ; int *create, imno, noelem[256], noelembis,ocol[256],colf; int *keyival[256], *ipos,ontype; int null, nl, unit; int naxis,npix[3]; float *keyrval[256],ms[2]; double *keydval[256],start[3],step[3]; char incata[60],intable[60],outable[60],filename[60]; char *cdummy, type,*keycval[256]; char form[1+TBL_FORLEN],*temp, *otype; char *keyname,*label,*area,defaul[5]; char *keyword = "descr_iname"; status = SCSPRO("TDATABASE"); status = SCKGETC("IN_A",1,60,&dummy,incata); status = SCKGETC("IN_B",1,60,&dummy,intable); status = SCKGETC("OUT_A",1,60,&dummy,outable); /*open table containing keywords names */ status = TCTOPN(intable,F_I_MODE,&tid) ; status = TCIGET(tid,&dummy,&nrow,&dummy,&dummy,&dummy); status = SCCSHO(incata,&nocat,&dummy); status = TCTINI(outable,F_TRANS,F_IO_MODE,nrow,nocat,&otid); status = TCCINI(otid,D_C_FORMAT,60L,"A16"," ","FILENAME",&colf); status = TCCSER(tid,keyword,&kcol); keyname = osmmget(NM*nrow); otype = osmmget(NT*nrow); nl = TBL_LABLEN+1; label = osmmget(nl*nocat); ipos = (int *)osmmget(nrow*sizeof(int)); create = (int *)osmmget((nrow+2)*sizeof(int)); for (i=0; i