source: XIOS/dev/dev_olga/src/transformation/domain_algorithm_extract.hpp @ 1620

Last change on this file since 1620 was 1549, checked in by oabramkina, 2 years ago

Adding a new domain transformation "domain_extract".

For now it has only the functionalities of zoom.

File size: 1.9 KB
Line 
1
2#ifndef __XIOS_DOMAIN_ALGORITHM_EXTRACT_HPP__
3#define __XIOS_DOMAIN_ALGORITHM_EXTRACT_HPP__
4
5#include "domain_algorithm_transformation.hpp"
6#include "transformation.hpp"
7
8namespace xios {
9
10class CDomain;
11class CExtractDomain;
12
13/*!
14  \class CDomainAlgorithmExtract
15  Implementing extract (alternative zoom) on domain
16*/
17class CDomainAlgorithmExtract : public CDomainAlgorithmTransformation
18{
19public:
20  CDomainAlgorithmExtract(CDomain* domainDestination, CDomain* domainSource, CExtractDomain* extractDomain);
21
22  virtual ~CDomainAlgorithmExtract() {}
23
24  static bool registerTrans();
25protected:
26  void updateDomainAttributes();
27  void computeIndexSourceMapping_(const std::vector<CArray<double,1>* >& dataAuxInputs);
28
29private:
30  void updateExtract();
31
32private:
33  //! Global extract begin on domain
34  int extractIBegin_;
35  int extractJBegin_;
36
37  //! Global extract end on domain
38  int extractIEnd_;
39  int extractJEnd_;
40
41  //! Global extract size on domain
42  int extractNi_;
43  int extractNj_;
44
45private:
46
47  static CGenericAlgorithmTransformation* create(CGrid* gridDst, CGrid* gridSrc,
48                                                CTransformation<CDomain>* transformation,
49                                                int elementPositionInGrid,
50                                                std::map<int, int>& elementPositionInGridSrc2ScalarPosition,
51                                                std::map<int, int>& elementPositionInGridSrc2AxisPosition,
52                                                std::map<int, int>& elementPositionInGridSrc2DomainPosition,
53                                                std::map<int, int>& elementPositionInGridDst2ScalarPosition,
54                                                std::map<int, int>& elementPositionInGridDst2AxisPosition,
55                                                std::map<int, int>& elementPositionInGridDst2DomainPosition);
56};
57
58}
59#endif // __XIOS_DOMAIN_ALGORITHM_EXTRACT_HPP__
Note: See TracBrowser for help on using the repository browser.