Changeset 2200 for trunk/external-alma/atnf
- Timestamp:
- 06/23/11 18:02:32 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/external-alma/atnf/PKSIO/NROReader.cc
r2198 r2200 39 39 #include <atnf/PKSIO/ASTEDataset.h> 40 40 41 #include <measures/Measures/MEpoch.h> 42 #include <measures/Measures/MPosition.h> 41 43 #include <measures/Measures/MDirection.h> 42 44 #include <measures/Measures/MCDirection.h> 45 #include <measures/Measures/MeasFrame.h> 43 46 #include <measures/Measures/MeasConvert.h> 44 47 … … 359 362 else if ( icoord == 2 ) { 360 363 // convert from AZEL to RADEC 364 vector<double> antpos = getAntennaPosition() ; 365 Vector<Quantity> qantpos( 3 ) ; 366 for ( int ip = 0 ; ip < 3 ; ip++ ) 367 qantpos[ip] = Quantity( antpos[ip], "m" ) ; 368 Double scantime = Double( dataset_->getScanTime( i ) ) ; 369 MEpoch me( Quantity( scantime, "d" ), MEpoch::UTC ) ; 370 MPosition mp( MVPosition( qantpos ), MPosition::ITRF ) ; 371 MeasFrame mf( me, mp ) ; 361 372 MDirection result = 362 373 MDirection::Convert( MDirection( Quantity( dirx, "rad" ), 363 374 Quantity( diry, "rad" ), 364 375 MDirection::Ref( MDirection::AZEL ) ), 365 MDirection::Ref( MDirection::J2000 ) ) () ;376 MDirection::Ref( MDirection::J2000, mf ) ) () ; 366 377 v = result.getAngle().getValue() ; 367 378 //cout << "NROReader::getDirection() DIRECTION convert from (" … … 441 452 //cout << "antpos = " << antpos << endl ; 442 453 string eq = dataset_->getEPOCH() ; 443 if ( eq.compare( 0, 5, "B1950" ) == 0 ) 444 equinox = 1950.0 ; 445 else if ( eq.compare( 0, 5, "J2000" ) == 0 ) 446 equinox = 2000.0 ; 454 // if ( eq.compare( 0, 5, "B1950" ) == 0 ) 455 // equinox = 1950.0 ; 456 // else if ( eq.compare( 0, 5, "J2000" ) == 0 ) 457 // equinox = 2000.0 ; 458 // equinox is always 2000.0 459 equinox = 2000.0 ; 447 460 //cout << "equinox = " << equinox << endl ; 448 461 string vref = dataset_->getVREF() ;
Note:
See TracChangeset
for help on using the changeset viewer.