Changeset 25784 for trunk/ippTools/src/flatcorr.c
- Timestamp:
- Oct 6, 2009, 9:22:42 AM (17 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/flatcorr.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/flatcorr.c
r24140 r25784 39 39 static bool addchipMode(pxConfig *config); 40 40 static bool addcameraMode(pxConfig *config); 41 static bool advancecameraMode(pxConfig *config); 41 42 static bool dropchipMode(pxConfig *config); 42 43 static bool dropcameraMode(pxConfig *config); … … 73 74 MODECASE(FLATCORR_MODE_ADDCHIP, addchipMode); 74 75 MODECASE(FLATCORR_MODE_ADDCAMERA, addcameraMode); 76 MODECASE(FLATCORR_MODE_ADVANCECAMERA, advancecameraMode); 75 77 MODECASE(FLATCORR_MODE_DROPCHIP, dropchipMode); 76 78 MODECASE(FLATCORR_MODE_DROPCAMERA, dropcameraMode); … … 297 299 // start a transaction so we don't end up with an exp without any associted 298 300 // imfiles 299 if (!psDBTransaction(config->dbh)) {300 psError(PS_ERR_UNKNOWN, false, "database error");301 return false;302 }301 // if (!psDBTransaction(config->dbh)) { 302 // psError(PS_ERR_UNKNOWN, false, "database error"); 303 // return false; 304 // } 303 305 304 306 // create a new flatcorrRun … … 333 335 row->corr_id = corr_id; 334 336 337 // if (!psDBCommit(config->dbh)) { 338 // psError(PS_ERR_UNKNOWN, false, "database error"); 339 // return false; 340 // } 341 335 342 flatcorrRunPrintObject (stdout, row, !simple); 336 343 return true; … … 378 385 } 379 386 387 static bool addcameraMode(pxConfig *config) 388 { 389 PS_ASSERT_PTR_NON_NULL(config, false); 390 391 // required 392 PXOPT_LOOKUP_S64(corr_id, config->args, "-corr_id", true, false); 393 PXOPT_LOOKUP_S64(chip_id, config->args, "-chip_id", true, false); 394 PXOPT_LOOKUP_S64(cam_id, config->args, "-cam_id", true, false); 395 396 // add a flatcorrCamLink (initial state has include = TRUE) 397 // XXX should add checks that the chip_id and corr_id are in ChipLink 398 if (!flatcorrCamLinkInsert(config->dbh, corr_id, chip_id, cam_id, 1)) { 399 psError(PS_ERR_UNKNOWN, false, "database error"); 400 return false; 401 } 402 403 return true; 404 } 405 380 406 // select the flatcorr chip runs that have completed and for which there is no camera entry 381 407 // queue a new camera run for them 382 static bool ad dcameraMode(pxConfig *config)408 static bool advancecameraMode(pxConfig *config) 383 409 { 384 410 PS_ASSERT_PTR_NON_NULL(config, false);
Note:
See TracChangeset
for help on using the changeset viewer.
