Changeset 15812 for trunk/psModules
- Timestamp:
- Dec 13, 2007, 11:50:56 AM (19 years ago)
- Location:
- trunk/psModules/src
- Files:
-
- 2 edited
-
camera/pmFPAfileIO.c (modified) (1 diff)
-
detrend/pmDetrendDB.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/camera/pmFPAfileIO.c
r15674 r15812 685 685 psMetadata *menu = psMetadataLookupMetadata(&status, file->camera, "CLASSID"); // Menu of class IDs 686 686 if (!status || !menu) { 687 psWarning("Unable to find CLASSID metadata in camera configuration --- " 688 "assuming no class identifier required."); 689 } else { 690 const char *rule = psMetadataLookupStr(&status, menu, file->detrend->level); // Rule for class_id 691 if (!status || !rule || strlen(rule) == 0) { 692 psWarning("Unable to find %s in CLASSID within camera configuration --- " 693 "attempting to proceed without it.", file->detrend->level); 694 } else { 695 classId = pmFPAfileNameFromRule(rule, file, view); 696 if (!classId) { 697 psError(PS_ERR_IO, false, "error converting CLASSID rule to name: %s\n", rule); 698 return false; 699 } 700 } 701 } 687 psError(PS_ERR_IO, false, "Unable to find CLASSID metadata in camera configuration"); 688 return false; 689 } 690 const char *rule = psMetadataLookupStr(&status, menu, file->detrend->level); // Rule for class_id 691 if (!status || !rule || strlen(rule) == 0) { 692 psError(PS_ERR_IO, false, "Unable to find %s in CLASSID in camera configuration", file->detrend->level); 693 return false; 694 } 695 classId = pmFPAfileNameFromRule(rule, file, view); 696 if (!classId) { 697 psError(PS_ERR_IO, false, "error converting CLASSID rule to name: %s\n", rule); 698 return false; 699 } 702 700 psTrace ("psModules.camera", 6, "looking for detrend (%s, %s)\n", file->detrend->detID, classId); 703 701 psFree (file->filename); -
trunk/psModules/src/detrend/pmDetrendDB.c
r15562 r15812 253 253 psStringAppend (&line, "detselect -select %s", detID); 254 254 if (classID && strlen(classID) > 0) { 255 psStringAppend(&line, " -class_id %s", classID);255 psStringAppend(&line, " -class_id %s", classID); 256 256 } 257 257 pmConfigDatabaseCommand(&line, config); … … 285 285 goto failure; 286 286 } 287 psMetadataItem *item = psMetadataLookup (answer, "detNormalizedImfile"); 288 if ((item->type == PS_DATA_METADATA_MULTI) && (item->data.list->n > 1)) { 289 psError(PS_ERR_IO, false, "detselect returned too many files\n"); 290 goto failure; 291 } 292 287 293 psMetadata *md = psMetadataLookupPtr (NULL, answer, "detNormalizedImfile"); 288 294 if (!md) {
Note:
See TracChangeset
for help on using the changeset viewer.
