IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Sep 18, 2006, 11:20:24 AM (20 years ago)
Author:
Paul Price
Message:

Making sure CELL.XPARITY and CELL.YPARITY (along with some others) are set when copying or mosaicking

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/camera/pmFPACopy.c

    r8815 r8823  
    7474    psArray *sourceReadouts = source->readouts; // The source readouts
    7575    int numReadouts = sourceReadouts->n; // Number of readouts copied
     76
     77    // Copy the value for a concept
     78    #define COPY_CONCEPT(TARGET, SOURCE, NAME, TYPE) \
     79    psMetadataItem *targetItem = psMetadataLookup(TARGET, NAME); \
     80    psMetadataItem *sourceItem = psMetadataLookup(SOURCE, NAME); \
     81    targetItem->data.TYPE = sourceItem->data.TYPE;
    7682
    7783    // Need to check/change CELL.XPARITY and CELL.YPARITY
     
    8793                xFlip = true;
    8894            }
     95        } else
     96        {
     97            // Use the source parity
     98            COPY_CONCEPT(target->concepts, source->concepts, "CELL.XPARITY", S32);
    8999        }
    90100        int yParityTarget = psMetadataLookupS32(&mdok, target->concepts, "CELL.YPARITY"); // Target y parity
     
    95105                yFlip = true;
    96106            }
     107        } else
     108        {
     109            // Use the source parity
     110            COPY_CONCEPT(target->concepts, source->concepts, "CELL.YPARITY", S32);
    97111        }
    98112        psTrace("psModules.camera", 3, "xFlip: %d; yFlip: %d\n", xFlip, yFlip);
Note: See TracChangeset for help on using the changeset viewer.