Changeset 26893 for trunk/psModules/src/camera/pmFPAMosaic.c
- Timestamp:
- Feb 10, 2010, 7:34:39 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/psModules/src/camera/pmFPAMosaic.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/camera/pmFPAMosaic.c
r25383 r26893 626 626 bool good = true; // Is everything good? 627 627 628 const char *cellName = psMetadataLookupStr(NULL, cell->concepts, "CELL.NAME"); // Name of cell 629 const char *chipName = psMetadataLookupStr(NULL, cell->parent->concepts, "CHIP.NAME"); // Name of chip 630 628 631 // Offset of the cell on the chip 629 632 int x0Cell = psMetadataLookupS32(&mdok, cell->concepts, "CELL.X0"); 630 633 if (!mdok) { 631 psError(PS_ERR_UNKNOWN, true, "CELL.X0 for cell is not set.\n");634 psError(PS_ERR_UNKNOWN, true, "CELL.X0 for cell %s,%s is not set.\n", chipName, cellName); 632 635 good = false; 633 636 } 634 637 int y0Cell = psMetadataLookupS32(&mdok, cell->concepts, "CELL.Y0"); 635 638 if (!mdok) { 636 psError(PS_ERR_UNKNOWN, true, "CELL.Y0 for cell is not set.\n");639 psError(PS_ERR_UNKNOWN, true, "CELL.Y0 for cell %s,%s is not set.\n", chipName, cellName); 637 640 good = false; 638 641 } 639 psTrace("psModules.camera", 5, "Cell %ld: x0=%d y0=%d\n", index, x0Cell, y0Cell); 642 psTrace("psModules.camera", 5, "Cell %s,%s (%ld): x0=%d y0=%d\n", 643 chipName, cellName, index, x0Cell, y0Cell); 640 644 641 645 // Offset of the chip on the FPA … … 649 653 x0Chip = psMetadataLookupS32(&mdok, chip->concepts, "CHIP.X0"); 650 654 if (!mdok) { 651 psError(PS_ERR_UNKNOWN, true, "CHIP.X0 for chip is not set.\n");655 psError(PS_ERR_UNKNOWN, true, "CHIP.X0 for chip %s is not set.\n", chipName); 652 656 good = false; 653 657 } 654 658 y0Chip = psMetadataLookupS32(&mdok, chip->concepts, "CHIP.Y0"); 655 659 if (!mdok) { 656 psError(PS_ERR_UNKNOWN, true, "CHIP.Y0 for chip is not set.\n");660 psError(PS_ERR_UNKNOWN, true, "CHIP.Y0 for chip %s is not set.\n", chipName); 657 661 good = false; 658 662 } … … 662 666 xBin->data.S32[index] = psMetadataLookupS32(&mdok, cell->concepts, "CELL.XBIN"); 663 667 if (!mdok || xBin->data.S32[index] == 0) { 664 psError(PS_ERR_UNKNOWN, true, "CELL.XBIN for cell is not set.\n");668 psError(PS_ERR_UNKNOWN, true, "CELL.XBIN for cell %s,%s is not set.\n", chipName, cellName); 665 669 return false; 666 670 } else if (xBin->data.S32[index] < *xBinMin) { … … 669 673 yBin->data.S32[index] = psMetadataLookupS32(&mdok, cell->concepts, "CELL.YBIN"); 670 674 if (!mdok || yBin->data.S32[index] == 0) { 671 psError(PS_ERR_UNKNOWN, true, "CELL.YBIN for cell is not set.\n");675 psError(PS_ERR_UNKNOWN, true, "CELL.YBIN for cell %s,%s is not set.\n", chipName, cellName); 672 676 return false; 673 677 } else if (yBin->data.S32[index] < *yBinMin) { … … 678 682 int xParityCell = psMetadataLookupS32(&mdok, cell->concepts, "CELL.XPARITY"); 679 683 if (!mdok || (xParityCell != 1 && xParityCell != -1)) { 680 psError(PS_ERR_UNKNOWN, true, "CELL.XPARITY for cell is not set.\n");684 psError(PS_ERR_UNKNOWN, true, "CELL.XPARITY for cell %s,%s is not set.\n", chipName, cellName); 681 685 return false; 682 686 } 683 687 int yParityCell = psMetadataLookupS32(&mdok, cell->concepts, "CELL.YPARITY"); 684 688 if (!mdok || (yParityCell != 1 && yParityCell != -1)) { 685 psError(PS_ERR_UNKNOWN, true, "CELL.YPARITY for cell is not set.\n");689 psError(PS_ERR_UNKNOWN, true, "CELL.YPARITY for cell %s,%s is not set.\n", chipName, cellName); 686 690 return false; 687 691 } … … 693 697 xParityChip = psMetadataLookupS32(&mdok, chip->concepts, "CHIP.XPARITY"); 694 698 if (!mdok || (xParityChip != 1 && xParityChip != -1)) { 695 psError(PS_ERR_UNKNOWN, true, "CHIP.XPARITY for chip is not set.\n");699 psError(PS_ERR_UNKNOWN, true, "CHIP.XPARITY for chip %s is not set.\n", chipName); 696 700 return false; 697 701 } 698 702 yParityChip = psMetadataLookupS32(&mdok, chip->concepts, "CHIP.YPARITY"); 699 703 if (!mdok || (yParityChip != 1 && yParityChip != -1)) { 700 psError(PS_ERR_UNKNOWN, true, "CHIP.YPARITY for chip is not set.\n");704 psError(PS_ERR_UNKNOWN, true, "CHIP.YPARITY for chip %s is not set.\n", chipName); 701 705 return false; 702 706 }
Note:
See TracChangeset
for help on using the changeset viewer.
