IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 3, 2006, 5:57:35 PM (20 years ago)
Author:
Paul Price
Message:

Code coming together, doesn't yet compile

Location:
trunk/ppMerge/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppMerge/src

    • Property svn:ignore set to
      .deps
      Makefile
      Makefile.in
  • trunk/ppMerge/src/ppMerge.c

    r6903 r7061  
    11#include <stdio.h>
    2 #include "pslib.h"
    3 #include "pmConcepts.h"
     2#include <pslib.h>
     3#include <psmodules.h>
     4
    45#include "ppMerge.h"
    56#include "ppMem.h"
     
    1314
    1415    // Parse the configuration and arguments
    15     ppImageConfig(config, argc, argv);
    16 
    17     // Open the input image, output image, output mask
    18     // Get camera configuration from header if not already defined
     16    // Open the input image(s)
     17    // Determine camera, format from header if not already defined
    1918    // Construct camera in preparation for reading
    20     ppImageParseCamera(data, config);
     19    pmConfig *config = ppMergeConfig(&argc, argv);
    2120
    2221    // Set various tasks (define optional operations)
    23     ppImageOptionsParse(data, options, config);
     22    ppMergeOptions *options = ppMergeOptionsParse(config);
    2423
    25     // open detrend images, load headers, optionally load pixels
    26     ppImageParseDetrend(data, options, config);
     24    // Check the inputs
     25    ppMergeData *data = ppMergeCheckInputs(options, config);
     26    if (!data) {
     27        psError("Not enough valid input files.\n");
     28        exit(EXIT_FAILURE);
     29    }
    2730
    28     // Image Arithmetic Loop
    29     ppImageLoop(data, options, config);
     31    // Measure the background in each image
     32    psImage *scale = NULL;              // The scalings
     33    psImage *zero = NULL;               // The zeros
     34    ppMergeScaleZero(&scale, &zero, data, options, config);
     35
     36    // Do the combination and write
     37    ppMergeCombine(scale, zero, data, options, config);
    3038
    3139    // Cleaning up
    3240    psFree(data);
     41    psFree(scale);
     42    psFree(zero);
    3343    psFree(options);
    3444    psFree(config);
     45
    3546    psTimerStop();
    3647    psTraceReset();
     48    psErrorClear();
    3749    pmConceptsDone();
     50    pmConfigDone();
     51
    3852    ppMemCheck();
    3953
Note: See TracChangeset for help on using the changeset viewer.