Changeset 12461 for trunk/Ohana/src/addstar
- Timestamp:
- Mar 15, 2007, 3:47:22 PM (19 years ago)
- Location:
- trunk/Ohana/src/addstar
- Files:
-
- 3 edited
-
include/addstar.h (modified) (1 diff)
-
src/ReadStarsFITS.c (modified) (3 diffs)
-
src/gstars.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/addstar/include/addstar.h
r11752 r12461 196 196 Missing *sort_missing PROTO((Average *average, int Naverage, Missing *missing, int Nmissing, int *next_miss)); 197 197 Stars *ConvertSMPDATA PROTO((FTable *table, int *nstars)); 198 // Stars *ConvertPS1DATAPROTO((FTable *table, int *nstars));198 Stars *ConvertPS1_DEV_0 PROTO((FTable *table, int *nstars)); 199 199 int ImageOptions PROTO((AddstarClientOptions *options, Image *images, int Nimages)); 200 200 int GetFileMode PROTO((Header *header)); -
trunk/Ohana/src/addstar/src/ReadStarsFITS.c
r12332 r12461 34 34 stars = ConvertSMPDATA (&table, &Nstars); 35 35 } 36 # if (0) 37 if (!strcmp (type, "PS1DATA")) { 38 stars = ConvertPS1DATA (&table, &Nstars); 36 if (!strcmp (type, "PS1_DEV_0")) { 37 stars = ConvertPS1_DEV_0 (&table, &Nstars); 39 38 } 40 # endif41 39 if (stars == NULL) { 42 40 fprintf (stderr, "ERROR: invalid table type %s\n", type); … … 60 58 /* XXX we need to check at least the size of the loaded table */ 61 59 60 // XXX use memset to zero-out the elements before setting 62 61 ALLOCATE (stars, Stars, Nstars); 63 62 for (i = 0; i < Nstars; i++) { … … 78 77 } 79 78 80 # if (0) 81 Stars *ConvertPS1DATA (FTable *table, int *nstars) { 79 Stars *ConvertPS1_DEV_0 (FTable *table, int *nstars) { 82 80 83 81 int i, Nstars; 84 82 Stars *stars; 85 PS1 Data*ps1data;83 PS1_DEV_0 *ps1data; 86 84 87 ps1data = gfits_table_get 1Data(table, &Nstars, NULL);85 ps1data = gfits_table_get_PS1_DEV_0 (table, &Nstars, NULL); 88 86 89 87 ALLOCATE (stars, Stars, Nstars); 90 88 for (i = 0; i < Nstars; i++) { 91 stars[i].X = ps1data[i].X; 92 stars[i].Y = ps1data[i].Y; 93 stars[i].M = ps1data[i].M; 94 stars[i].dM = ps1data[i].dM; 95 stars[i].dophot = ps1data[i].dophot; 89 stars[i].X = ps1data[i].X; 90 stars[i].Y = ps1data[i].Y; 91 stars[i].dX = ps1data[i].dX; 92 stars[i].dY = ps1data[i].dY; 93 stars[i].M = ps1data[i].M; 94 stars[i].dM = ps1data[i].dM; 95 stars[i].Mpeak = ps1data[i].Mpeak; 96 96 97 stars[i].Mgal = ps1data[i].M; 98 stars[i].Map = ps1data[i].dM; 99 stars[i].fx = ps1data[i].fx; 100 stars[i].fy = ps1data[i].fy; 101 stars[i].df = ps1data[i].df; 97 stars[i].sky = ps1data[i].sky; 98 stars[i].dsky = ps1data[i].dSky; 99 100 stars[i].fx = ps1data[i].fx; 101 stars[i].fy = ps1data[i].fy; 102 stars[i].df = ps1data[i].df; 103 104 stars[i].psfProb = ps1data[i].psfProb; 105 stars[i].psfQual = ps1data[i].psfQual; 106 107 stars[i].detID = ps1data[i].detID; 108 109 /* these are set elsewhere */ 110 stars[i].R = 0.0; 111 stars[i].D = 0.0; 112 stars[i].dR = 0.0; 113 stars[i].dD = 0.0; 114 115 stars[i].uR = 0.0; 116 stars[i].uD = 0.0; 117 stars[i].duR = 0.0; 118 stars[i].duD = 0.0; 119 120 stars[i].P = 0.0; 121 stars[i].dP = 0.0; 122 123 stars[i].Mcal = 0; 124 stars[i].t = 0; 125 stars[i].dt = 0; 126 stars[i].airmass = 0; 127 stars[i].code = 0; 128 stars[i].found = 0; 129 130 /* these are not used */ 131 stars[i].Map = NO_MAG; 132 stars[i].Mgal = NO_MAG; 133 stars[i].dophot = 0; 102 134 } 103 135 *nstars = Nstars; 104 136 return (stars); 105 137 } 106 # endif -
trunk/Ohana/src/addstar/src/gstars.c
r12332 r12461 156 156 extsize[i] = headers[i][0].size + gfits_matrix_size (headers[i]); 157 157 gfits_scan (headers[i], "EXTTYPE", "%s", 1, tmpword); 158 158 159 if (!strcmp (tmpword, "SMPDATA") || 159 !strcmp (tmpword, "PS1DATA")) { 160 !strcmp (tmpword, "PS1_DEV_0")) { 161 160 162 exttype[Nimage] = strcreate (tmpword); 161 163 gfits_scan (headers[i], "EXTNAME", "%s", 1, tmpword);
Note:
See TracChangeset
for help on using the changeset viewer.
