Changeset 6083 for trunk/ippTools/src
- Timestamp:
- Jan 20, 2006, 11:11:25 AM (21 years ago)
- Location:
- trunk/ippTools/src
- Files:
-
- 2 edited
-
p2rawToPending.c (modified) (1 diff)
-
p2searchRawFrames.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/p2rawToPending.c
r6063 r6083 4 4 psArray *p2rawToPending (p2Config *config, psArray *rawFrames) { 5 5 6 psArray *pendingFrames = psArrayAlloc (rawFrames->n);6 psArray *pendingFrames = psArrayAlloc(rawFrames->n); 7 7 pendingFrames->n = 0; 8 8 -
trunk/ippTools/src/p2searchRawFrames.c
r6073 r6083 2 2 3 3 // select raw frames (exposure+images) which match the given config options 4 psArray *p2searchRawFrames (p2Config *config) {4 psArray *p2searchRawFrames(p2Config *config) { 5 5 6 6 // build 'where' structure 7 7 psMetadata *where = psMetadataAlloc (); 8 8 9 psMetadataAddS32 (where, PS_LIST_TAIL, "TYPE", 0, "==", P2_TYPE_OBJECT);9 // psMetadataAddS32 (where, PS_LIST_TAIL, "TYPE", 0, "==", P2_TYPE_OBJECT); 10 10 11 11 if (config->camera != NULL) { 12 psMetadataAddStr (where, PS_LIST_TAIL, "CAMERA", 0, "==", config->camera_name);12 psMetadataAddStr(where, PS_LIST_TAIL, "camera", 0, "==", config->camera_name); 13 13 } 14 14 if (config->filter != NULL) { 15 psMetadataAddStr (where, PS_LIST_TAIL, "FILTER", 0, "==", config->filter);15 psMetadataAddStr(where, PS_LIST_TAIL, "filter", 0, "==", config->filter); 16 16 } 17 17 // psMetadataConfig does not support times yet … … 23 23 */ 24 24 25 psArray *exposures = rawScienceExpSelectRowObjects (config->database, where, MAX_ROWS); 25 psArray *exposures = rawScienceExpSelectRowObjects(config->database, where, 26 MAX_ROWS); 26 27 psFree (where); 27 28 if (!exposures) { … … 32 33 33 34 // output array of ppRawFrame 34 psArray *frames = psArrayAlloc (exposures->n);35 psArray *frames = psArrayAlloc(exposures->n); 35 36 36 37 // 'where' to select each exposure … … 39 40 rawScienceExpRow *exposure = exposures->data[i]; 40 41 41 psMetadataAddStr (where, PS_LIST_TAIL, "EXP_ID", PS_META_REPLACE, "==", exposure->exp_id); 42 psMetadataAddStr(where, PS_LIST_TAIL, "exp_id", PS_META_REPLACE, "==", 43 exposure->exp_id); 42 44 43 psArray *images = rawImfileSelectRowObjects (config->database, where, MAX_ROWS); 45 psArray *images = rawImfileSelectRowObjects(config->database, where, 46 MAX_ROWS); 44 47 if (!images) { 45 48 psError(PS_ERR_UNKNOWN, false, "database access failed"); … … 48 51 } 49 52 50 ppRawFrame * frame = ppRawFrameAlloc(exposure, images);51 psArrayAdd (frames, 100, frame);53 ppRawFrame *rawFrame = ppRawFrameAlloc(exposure, images); 54 psArrayAdd(frames, 100, rawFrame); 52 55 } 53 56
Note:
See TracChangeset
for help on using the changeset viewer.
