Changeset 2657 for trunk/src/STWriter.cpp
- Timestamp:
- 10/10/12 12:17:12 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/STWriter.cpp
r2652 r2657 40 40 41 41 #include <atnf/PKSIO/PKSrecord.h> 42 #ifndef NOPKSMS43 #include <atnf/PKSIO/PKSMS2writer.h>44 #endif45 42 #include <atnf/PKSIO/PKSSDwriter.h> 46 43 #include <atnf/PKSIO/SrcType.h> … … 51 48 #include <tables/Tables/ArrayColumn.h> 52 49 50 #include <fits/FITS/FITSSpectralUtil.h> 51 53 52 #include "STFITSImageWriter.h" 54 53 #include "STAsciiWriter.h" … … 68 67 t.upcase(); 69 68 if (t == "MS2") { 70 #ifdef NOPKSMS71 69 throw (AipsError("MS2 OUTPUT FORMAT IS NO LONGER SUPPORTED")); 72 #else73 writer_ = new PKSMS2writer();74 #endif75 70 } else if (t == "SDFITS") { 76 71 writer_ = new PKSSDwriter(); … … 99 94 t.upcase(); 100 95 if (t== "MS2") { 101 #ifdef NOPKSMS102 96 throw (AipsError("MS2 OUTPUT FORMAT IS NO LONGER SUPPORTED")); 103 #else104 writer_ = new PKSMS2writer();105 #endif106 97 } else if (t== "SDFITS") { 107 98 writer_ = new PKSSDwriter(); … … 121 112 // in asap on-the-fly. 122 113 114 String freqframe; 115 FITSSpectralUtil::specsysFromFrame(freqframe, 116 in->frequencies().getFrame(true)); 123 117 CountedPtr<Scantable> inst = in; 124 118 if (in->frequencies().getFrame(true) != in->frequencies().getFrame(false)) { 119 FITSSpectralUtil::specsysFromFrame(freqframe, 120 in->frequencies().getFrame(false)); 121 125 122 STMath stm(false); 126 123 inst = stm.frequencyAlign(in); … … 151 148 // before. Need to check with the Offline User Test data 152 149 STHeader hdr = inst->getHeader(); 153 //const Int nPol = hdr.npol;154 //const Int nChan = hdr.nchan;155 150 std::vector<uint> ifs = inst->getIFNos(); 156 151 int nIF = inst->nif();//ifs.size(); … … 177 172 // Create the output file and write static data. 178 173 Int status; 179 // status = writer_->create(String(filename), hdr.observer, hdr.project,180 // hdr.antennaname, hdr.antennaposition,181 // hdr.obstype, hdr.fluxunit,182 // hdr.equinox, hdr.freqref,183 // nChan, nPol, havexpol, False);184 174 status = writer_->create(String(filename), hdr.observer, hdr.project, 185 175 inst->getAntennaName(), hdr.antennaposition, 186 176 hdr.obstype, hdr.fluxunit, 187 hdr.equinox, hdr.freqref,177 hdr.equinox, freqframe, 188 178 nChan, nPol, havexpol, False); 189 179 if ( status ) {
Note: See TracChangeset
for help on using the changeset viewer.