Line data Source code
1 : // -*- C++ -*-
2 : //# FortranizedLoopsFromGrid.cc: Code to call the de-gridding
3 : //# inner-loops written in FORTRAN
4 : //# Copyright (C) 1997,1998,1999,2000,2001,2002,2003
5 : //# Associated Universities, Inc. Washington DC, USA.
6 : //#
7 : //# This library is free software; you can redistribute it and/or modify it
8 : //# under the terms of the GNU Library General Public License as published by
9 : //# the Free Software Foundation; either version 2 of the License, or (at your
10 : //# option) any later version.
11 : //#
12 : //# This library is distributed in the hope that it will be useful, but WITHOUT
13 : //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 : //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
15 : //# License for more details.
16 : //#
17 : //# You should have received a copy of the GNU Library General Public License
18 : //# along with this library; if not, write to the Free Software Foundation,
19 : //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
20 : //#
21 : //# Correspondence concerning AIPS++ should be addressed as follows:
22 : //# Internet email: aips2-request@nrao.edu.
23 : //# Postal address: AIPS++ Project Office
24 : //# National Radio Astronomy Observatory
25 : //# 520 Edgemont Road
26 : //# Charlottesville, VA 22903-2475 USA
27 : //#
28 : //# $Id$
29 : {
30 : const Complex *gridPtr;
31 : Complex *phaseGradPtr;
32 : Int *supportPtr, *cfShapePtr,
33 : *locPtr, *igrdposPtr, //*ilocPtr, *tilocPtr,
34 : *convOriginPtr;
35 : Float *samplingPtr;
36 : Double *offPtr;
37 : Bool dummy;
38 :
39 0 : gridPtr = grid.getStorage(dummy);
40 0 : phaseGradPtr = cached_phaseGrad_p.getStorage(dummy);
41 0 : supportPtr = support.getStorage(dummy);
42 0 : samplingPtr = sampling.getStorage(dummy);
43 0 : cfShapePtr = cfShape.getStorage(dummy);
44 0 : locPtr = loc.getStorage(dummy);
45 0 : igrdposPtr = igrdpos.getStorage(dummy);
46 : //ilocPtr = iloc.getStorage(dummy);
47 : //tilocPtr = tiloc.getStorage(dummy);
48 0 : offPtr = off.getStorage(dummy);
49 0 : convOriginPtr = convOrigin.getStorage(dummy);
50 0 : Int finitePointingOffsets_int = (finitePointingOffset?1:0);
51 0 : Int cf0=cfShape(0), cf1=cfShape(1), cf2=cfShape(2), cf3=cfShape(3);
52 0 : Int gnx = nx, gny = ny, gnp = nGridPol, gnc=nGridChan;
53 0 : Int phx=cached_phaseGrad_p.shape()[0], phy=cached_phaseGrad_p.shape()[1];
54 :
55 : //
56 : // Call the FORTRAN function with the gridding inner-loops (in synthesis/fortran/faccumulateFromGrid.f)
57 : //
58 0 : faccumulatefromgrid_(&nvalue,
59 0 : &norm[ipol],
60 : gridPtr,
61 : convFuncV,
62 : &dataWVal,
63 : supportPtr,samplingPtr,offPtr, convOriginPtr,
64 : cfShapePtr,locPtr,igrdposPtr,
65 : &sinDPA, &cosDPA,
66 : &finitePointingOffsets_int,
67 : phaseGradPtr,
68 : &phasor,
69 : &gnx, &gny, &gnp, &gnc,
70 : &cf0, &cf1, &cf2, &cf3,
71 : &phx, &phy);
72 :
73 : // &nx,&ny,&nGridPol, &nGridChan,
74 : // &unity, &unity, &unity, &unity,
75 : // &cfShape(0),&cfShape(1),&cfShape(2),&cfShape(3),
76 : // &(cached_phaseGrad_p.shape()[0]),
77 : // &(cached_phaseGrad_p.shape()[1]));
78 : }
|