IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 19, 2006, 4:16:26 PM (21 years ago)
Author:
jhoblitt
Message:

compilation fixes
switch to using the metadatadb API

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/src/chiptool.h

    r6032 r6060  
    77# include <pmPSFtry.h>
    88# include <pmModelGroup.h>
     9# include <metadatadb.h>
    910
    1011// load these values from the db in the init stage
    1112# define P2_TYPE_OBJECT 1
    1213# define P2_STATE_READY 2
     14# define RECIPE "foo"
     15# define MAX_ROWS 10e9
    1316
    1417typedef enum {
     
    2528typedef struct {
    2629    p2mode mode;
    27     psTime start;
    28     psTime stop;
     30    psTime *start;
     31    psTime *stop;
    2932    psSphere r1;
    3033    psSphere r2;
    31     char *camera;
     34    psMetadata *camera;
     35    char *camera_name;
    3236    char *filter;
    3337    psDB *database;
    34 } p2config;
    35 
    36 // this structure should be defined using the mddb api tools
    37 typedef struct {
    38     char expID[32];                     // free-form exposure ID string
    39     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    40     int Nclass;                         // number of files of this class
    41     char camera[32];                    // free-form camera ID string
    42     char filter[32];                    // free-form filter ID string
    43     psTime time_start;                  // exposure start time
    44     psTime time_stop;                   // exposure stop time
    45     psTime exptime;                     // exposure duration (seconds)
    46     char exptype;                       // type of exposure: object (0), bias (1), dark (2), flat (3), etc
    47     float sky;                          // measure sky brightness
    48     float seeing;                       // measured image quality
    49     float dettemp;                      // temperature of detector
    50 } ppRawExposure;
    51 
    52 // this structure should be defined using the mddb api tools
    53 typedef struct {
    54     char expID[32];                     // free-form exposure ID string
    55     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    56     char classID[32];                   // identifier for class (chip00, cell00, etc)
    57     char url[128];                      // locator for file (neb / file)
    58     char state;                         // current load state
    59 } ppRawImfile;
    60 
    61 // this structure should be defined using the mddb api tools
    62 typedef struct {
    63     char expID[32];                     // free-form exposure ID string
    64     psU8 P2version;
    65     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    66     int Nclass;                         // number of files of this class
    67     psU8 P1version;
    68 } p2PendingExposure;
    69 
    70 // this structure should be defined using the mddb api tools
    71 typedef struct {
    72     char expID[32];                     // free-form exposure ID string
    73     char P2version;
    74     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    75     char classID[32];                   // identifier for class (chip00, cell00, etc)
    76     char urlroot[128];                  // locator for file (neb / file)
    77     char input[16];                     // extension for input image
    78     char output[16];                    // extension for output image
    79     char log[16];                       // extension for log file
    80     char smf[16];                       // extension for object table
    81 } p2PendingImfile;
    82 
    83 // this structure should be defined using the mddb api tools
    84 typedef struct {
    85     char expID[32];                     // free-form exposure ID string
    86     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    87     int Nclass;                         // number of files of this class
    88     int Ndone;                          // number of files of this class
    89     char P1version;
    90     char P2version;
    91     char state;
    92 } p2DoneExposure;
    93 
    94 // this structure should be defined using the mddb api tools
    95 typedef struct {
    96     char expID[32];                     // free-form exposure ID string
    97     char P2version;
    98     char class;                         // class of file: fpa (0), chip (1), cell (2), readout (3)?
    99     char classID[32];                   // identifier for class (chip00, cell00, etc)
    100     char urlroot[128];                  // locator for file (neb / file)
    101     char input[16];                     // extension for input image
    102     char output[16];                    // extension for output image
    103     char log[16];                       // extension for log file
    104     char smf[16];                       // extension for object table
    105     char state;                         // current P2 state
    106 } p2DoneImfile;
     38    psMetadata *site;
     39    psMetadata *recipe;
     40    psMetadata *arguments;
     41} p2Config;
    10742
    10843typedef struct {
    109     ppRawExposure *exposure;
     44    rawScienceExpRow *exposure;
    11045    psArray *images;
    11146} ppRawFrame;
    11247
     48ppRawFrame *ppRawFrameAlloc(
     49    rawScienceExpRow *exposure,
     50    psArray *images
     51);
     52
    11353typedef struct {
    114     ppPendingExposure *exposure;
     54    p2PendingExpRow *exposure;
    11555    psArray *images;
    11656} p2PendingFrame;
    11757
     58p2PendingFrame *p2PendingFrameAlloc(
     59    p2PendingExpRow *exposure,
     60    psArray *images
     61);
     62
    11863typedef struct {
    119     ppDoneExposure *exposure;
     64    p2DoneExpRow *exposure;
    12065    psArray *images;
    12166} p2DoneFrame;
    12267
     68p2DoneFrame *p2DoneFrameAlloc(
     69    p2DoneExpRow *exposure,
     70    psArray *images
     71);
     72
     73bool p2createTables (p2Config *config);
     74bool p2deleteTables (p2Config *config);
     75bool p2adminConfig (p2Config *config, int argc, char **argv);
     76bool p2searchConfig (p2Config *config, int argc, char **argv);
     77psArray *p2rawToPending (p2Config *config, psArray *rawFrames);
     78psArray *p2searchRawFrames (p2Config *config);
     79bool p2insertPendingFrames (p2Config *config, psArray *rawFrames);
     80psArray *p2searchPendingFrames (p2Config *config);
     81bool p2writePendingImages (p2Config *config, psArray *frames);
     82bool p2updatePendingFrames (p2Config *config, psArray *pendingFrames);
     83psArray *p2pendingToDone (p2Config *config, psArray *pendingFrames);
     84bool p2insertDoneFrames (p2Config *config, psArray *doneFrames);
     85bool psTimeIsZero(psTime *time);
     86bool p2writePendingFrames (p2Config *config, psArray *frames);
Note: See TracChangeset for help on using the changeset viewer.