Register.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU Lesser General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 #ifndef __TERRALIB_VP_INTERNAL_REGISTER_H
21 #define __TERRALIB_VP_INTERNAL_REGISTER_H
22 
23 #include "Config.h"
24 #include "../dataaccess/dataset/DataSet.h"
25 #include "../dataaccess/dataset/DataSetType.h"
26 #include "../dataaccess/utils/DataAccess.h"
27 
28 #include <tuple>
29 #include <vector>
30 #include <string>
31 namespace te
32 {
33  namespace vp
34  {
35  /*!
36  \namespace Register A namespace for functions to register vector data.
37  */
38  namespace Register
39  {
40  /*!
41  \enum RegisterMethod
42  \brief Register method.
43  */
45  {
46  InvalidRegMethod = 0, //!< Invalid type
47  TransByNMethod = 1 //!< Aplly a translation transform by using neighor tie-points.
48  };
49 
50  /*!
51  \typedef TiePointT
52  \brief Tie poit type definition [ SRID1, x1, y2, SRID2, x2, y2 ].
53  */
54  typedef std::tuple< int, double, double, int, double, double > TiePointT;
55 
56  /*!
57  \brief Register dataset geometries using supplied tie-points.
58  \param method Method to use.
59  \param tiePoints Input tie-points.
60  \param minNeighborTiePoints Minimum number of neighbor tie-points to use when registering each geometry point.
61  \param enableThreads Enable/disable the use of threads.
62  \param inDataset Input dataset.
63  \param inDsType Input dataset type.
64  \param outDataSetName Output dataset name.
65  \param outDataAccess Output data access where the registered dataset will be created.
66  \return true if ok, false on errors.
67  \note Tie points x1,y1 are source coords ( incorrect/adjust coord );
68  \note Tie points x2,y2 are target coords ( correct/reference coord );
69  \note NEW_COORD(target) = OLD_COORD(source) + OFFSET
70  \note OFFSET = NEW_COORD(target) - OLD_COORD(source)
71  */
73  const RegisterMethod& method,
74  const std::vector< TiePointT >& tiePoints,
75  const unsigned int& minNeighborTiePoints,
76  const bool enableThreads,
77  te::da::DataSet& inDataset,
78  const te::da::DataSetType& inDsType,
79  const std::string& outDataSetName,
80  te::da::DataAccess& outDataAccess );
81 
82  } // end namespace Register
83  } // end namespace vp
84 } // end namespace te
85 
86 #endif // __TERRALIB_VP_INTERNAL_REGISTER_H
Class used to centralize and control access to data in terralib. It aims to create a high-level inter...
Definition: DataAccess.h:77
A class that models the description of a dataset.
Definition: DataSetType.h:73
A dataset is the unit of information manipulated by the data access module of TerraLib.
Definition: DataSet.h:114
RegisterMethod
Register method.
Definition: Register.h:45
@ TransByNMethod
Aplly a translation transform by using neighor tie-points.
Definition: Register.h:47
@ InvalidRegMethod
Invalid type.
Definition: Register.h:46
TEVPEXPORT bool RegisterDataset(const RegisterMethod &method, const std::vector< TiePointT > &tiePoints, const unsigned int &minNeighborTiePoints, const bool enableThreads, te::da::DataSet &inDataset, const te::da::DataSetType &inDsType, const std::string &outDataSetName, te::da::DataAccess &outDataAccess)
Register dataset geometries using supplied tie-points.
std::tuple< int, double, double, int, double, double > TiePointT
Tie poit type definition [ SRID1, x1, y2, SRID2, x2, y2 ].
Definition: Register.h:54
TerraLib.
#define TEVPEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:61
Proxy configuration file for TerraView (see terraview_config.h).