IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 23626


Ignore:
Timestamp:
Mar 30, 2009, 10:34:42 PM (17 years ago)
Author:
Paul Price
Message:

JD and MJD are converted to TAI.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/concepts/pmConceptsStandard.c

    r23625 r23626  
    11871187                                          const pmCell *cell)
    11881188{
     1189    psString timeName = psStringCopy(concept->name); // Name of corresponding TIME concept
     1190    psStringSubstitute(&timeName, "TIME", "TIMESYS");
     1191
     1192    conceptTimeFormat timeFormat = conceptGetTimeFormat(timeName, cameraFormat); // Format for time
     1193    psFree(timeName);
     1194
     1195    psTimeType timesys = concept->data.S32; // Time system
     1196
     1197    // JD and MJD are converted to TAI before writing
     1198    switch (timeFormat.format) {
     1199      case TIME_FORMAT_JD:
     1200      case TIME_FORMAT_MJD:
     1201        timesys = PS_TIME_TAI;
     1202        break;
     1203      default:
     1204        break;
     1205    }
     1206
    11891207    psString sys = NULL;            // String to store
    1190     switch (concept->data.S32) {
     1208    switch (timesys) {
    11911209      case PS_TIME_TAI:
    11921210        sys = psStringCopy("TAI");
Note: See TracChangeset for help on using the changeset viewer.