source: trunk/src/PlotHelper.h @ 2689

Last change on this file since 2689 was 2689, checked in by Kana Sugimoto, 11 years ago

New Development: Yes

JIRA Issue: No

Ready for Test: Yes

Interface Changes: No

What Interface Changed: a new cpp helper class to support asapplotter.plotgrid

Test Programs:

Put in Release Notes: No

Module(s):

Description:

Added a new cpp helper class to make asapplotter.plotgrid work with new STGrid
with more accurate wcs projection.


File size: 1.5 KB
Line 
1//
2// C++ Interface: PlotHelper
3//
4// Description:
5//    A small helper class to handle direction coordinate in asapplotter
6//
7// Author: Kana Sugimoto <kana.sugi@nao.ac.jp>, (C) 2012
8//
9// Copyright: See COPYING file that comes with this distribution
10//
11//
12#ifndef ASAPPLOTHELPER_H
13#define ASAPPLOTHELPER_H
14
15// STL
16#include <iostream>
17#include <string>
18#include <vector>
19// casacore
20#include <casa/aips.h>
21#include <casa/Utilities/CountedPtr.h>
22#include <coordinates/Coordinates/DirectionCoordinate.h>
23
24#include "ScantableWrapper.h"
25
26namespace asap {
27
28class PlotHelper
29{
30public:
31  /**
32   * constructors and a destructor
33   **/
34  PlotHelper();
35  explicit PlotHelper( const ScantableWrapper &s);
36
37  virtual ~PlotHelper();
38  /**
39   * Set scantable for automatic resolution of grid parameter
40   **/
41  void setScantable( const ScantableWrapper &s ) ;
42
43  /**
44   * Set grid parameters for plot panel (by values in radian)
45   **/
46  void setGridParamVal(const int nx, const int ny,
47                    const double cellx, const double celly,
48                    const double centx, const double centy,
49                    string epoch="J2000", const string projname="SIN") ;
50  /// TODO
51  /**
52   * Set grid parameters for plot panel (by quantity)
53   **/
54/*   void setGridParam(const int nx, const int ny,  */
55/*                  const string cellx="", const string celly="", */
56/*                  string center="", const string projname="SIN") ; */
57
58  /**
59   * Get Pixel position of a row
60   **/
61  vector<double> getGridPixel(const int whichrow=0);
62
63 private:
64  casa::DirectionCoordinate *dircoord_;
65  ScantableWrapper data_;
66
67};
68
69} // namespace
70
71#endif
Note: See TracBrowser for help on using the repository browser.