Line data Source code
1 : // -*- C++ -*- 2 : //# WOnlyConvFunc.h: Definition of the WOnlyConvFunc class 3 : //# Copyright (C) 1997,1998,1999,2000,2001,2002,2003 4 : //# Associated Universities, Inc. Washington DC, USA. 5 : //# 6 : //# This library is free software; you can redistribute it and/or modify it 7 : //# under the terms of the GNU Library General Public License as published by 8 : //# the Free Software Foundation; either version 2 of the License, or (at your 9 : //# option) any later version. 10 : //# 11 : //# This library is distributed in the hope that it will be useful, but WITHOUT 12 : //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 : //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public 14 : //# License for more details. 15 : //# 16 : //# You should have received a copy of the GNU Library General Public License 17 : //# along with this library; if not, write to the Free Software Foundation, 18 : //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA. 19 : //# 20 : //# Correspondence concerning AIPS++ should be addressed as follows: 21 : //# Internet email: casa-feedback@nrao.edu. 22 : //# Postal address: AIPS++ Project Office 23 : //# National Radio Astronomy Observatory 24 : //# 520 Edgemont Road 25 : //# Charlottesville, VA 22903-2475 USA 26 : //# 27 : //# $Id$ 28 : // 29 : #ifndef SYNTHESIS_WONLYCONVFUNC_H 30 : #define SYNTHESIS_WONLYCONVFUNC_H 31 : 32 : #include <synthesis/TransformMachines/ConvolutionFunction.h> 33 : #include <synthesis/TransformMachines/CFStore.h> 34 : #include <synthesis/TransformMachines/WTerm.h> 35 : #include <synthesis/TransformMachines/PSTerm.h> 36 : #include <casacore/images/Images/ImageInterface.h> 37 : #include <casacore/images/Images/TempImage.h> 38 : #include <casacore/casa/Logging/LogIO.h> 39 : #include <casacore/casa/Logging/LogSink.h> 40 : #include <casacore/casa/Logging/LogOrigin.h> 41 : #include <casacore/casa/Arrays/ArrayFwd.h> 42 : 43 : namespace casacore{ 44 : 45 : template<class T> class ImageInterface; 46 : 47 : } 48 : 49 : namespace casa { //# NAMESPACE CASA - BEGIN 50 : class VisBuffer; 51 : // 52 : //------------------------------------------------------------------------------------------- 53 : // 54 : class WOnlyConvFunc : public ConvolutionFunction 55 : { 56 : public: 57 : WOnlyConvFunc(const casacore::CountedPtr<WTerm>& wTerm, 58 : const casacore::CountedPtr<PSTerm>& psTerm): 59 : ConvolutionFunction(),wTerm_p(wTerm), psTerm_p(psTerm) 60 : {}; 61 : ~WOnlyConvFunc() {}; 62 : WOnlyConvFunc& operator=(const WOnlyConvFunc& other); 63 : 64 : 65 : void makeConvFunction(const casacore::ImageInterface<casacore::Complex>& image, 66 : const VisBuffer& vb, 67 : const casacore::Int wConvSize, 68 : const casacore::Float pa, 69 : CFStore& cfs, 70 : CFStore& cfwts); 71 : 72 0 : virtual int getVisParams(const VisBuffer& vb) {return wTerm_p->getVisParams(vb);}; 73 0 : virtual void setPolMap(const casacore::Vector<casacore::Int>& polMap) {wTerm_p->setPolMap(polMap);}; 74 : 75 : virtual casacore::Bool findSupport(casacore::Array<casacore::Complex>& func, casacore::Float& threshold,casacore::Int& origin, casacore::Int& R); 76 : 77 : // 78 : // Pedgree baggage (NoOps). 79 : // 80 0 : casacore::Bool makeAverageResponse(const VisBuffer& /*vb*/, 81 : const casacore::ImageInterface<casacore::Complex>& /*image*/, 82 : casacore::ImageInterface<casacore::Float>& /*theavgPB*/, 83 0 : casacore::Bool /*reset*/=true) {return false;}; 84 0 : casacore::Bool makeAverageResponse(const VisBuffer& /*vb*/, 85 : const casacore::ImageInterface<casacore::Complex>& /*image*/, 86 : casacore::ImageInterface<casacore::Complex>& /*theavgPB*/, 87 0 : casacore::Bool /*reset*/=true) {return false;}; 88 : protected: 89 : void setSupport(casacore::Array<casacore::Complex>& convFunc, CFStore& cfs); 90 : 91 : private: 92 : casacore::CountedPtr<WTerm> wTerm_p; 93 : casacore::CountedPtr<PSTerm> psTerm_p; 94 : }; 95 : // 96 : //------------------------------------------------------------------------------------------- 97 : // 98 : }; 99 : #endif