source: trunk/src/python_PlotHelper.cpp @ 2717

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

New Development: Yes

JIRA Issue: No

Ready for Test: Yes

Interface Changes: Yes

What Interface Changed: added a new method, set_grid(), in plothelper class.

Test Programs: test_sdplot[sdplot_gridTest]

Put in Release Notes: Yes

Module(s): asapplotter, sdplot(plottype='grid')

Description:

The method, asapplotter.plotgrid(), considers tangential projection
effects when getting grid center and extents from a scantable.
This affects behavior of plottype='grid' in sdplot task of CASA.

File size: 1.4 KB
Line 
1//#---------------------------------------------------------------------------
2//# python_PlotHelper.cpp: python exposure of c++ PlotHelper class
3//#---------------------------------------------------------------------------
4//# Author: Kanako Sugimoto, (C) 2012
5//#
6//# Copyright: See COPYING file that comes with this distribution
7//#
8//#---------------------------------------------------------------------------
9#include <boost/python.hpp>
10#include <boost/python/args.hpp>
11
12#include "PlotHelper.h"
13//#include "ScantableWrapper.h"
14
15using namespace boost::python;
16
17namespace asap {
18  namespace python {
19
20void python_PlotHelper() {
21  class_<PlotHelper>("plothelper")
22    .def( init <> () )
23    .def( init <ScantableWrapper> () )
24    .def("set_scan", &PlotHelper::setScantable)
25    .def("set_gridval", &PlotHelper::setGridParamVal,
26         (boost::python::arg("epoch")="J2000",
27          boost::python::arg("projname")="SIN"))
28    .def("set_grid", &PlotHelper::setGridParam,
29         (boost::python::arg("cellx")="",
30          boost::python::arg("celly")="",
31          boost::python::arg("center")="",
32          boost::python::arg("projname")="SIN") )
33    .def("get_gpos", &PlotHelper::getGridPixel,
34         (boost::python::arg("whichrow")=0) )
35    /** TODO
36    .def("get_gdir", &PlotHelper::getGridDirection)
37    .def("get_gdirval", &PlotHelper::getGridWorld)
38    **/
39    ;
40
41};
42
43  } // python
44} // asap
Note: See TracBrowser for help on using the repository browser.