lsst.afw  15.0-16-g953e39cab
IdentityXYTransform.cc
Go to the documentation of this file.
1 // -*- lsst-c++ -*-
2 
3 /*
4  * LSST Data Management System
5  * Copyright 2008, 2009, 2010 LSST Corporation.
6  *
7  * This product includes software developed by the
8  * LSST Project (http://www.lsst.org/).
9  *
10  * This program is free software: you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation, either version 3 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the LSST License Statement and
21  * the GNU General Public License along with this program. If not,
22  * see <http://www.lsstcorp.org/LegalNotices/>.
23  */
24 
26 #include <memory>
27 
28 namespace lsst {
29 namespace afw {
30 namespace geom {
31 
33 
39 
41  return std::make_shared<IdentityXYTransform>();
42 }
43 
44 Point2D IdentityXYTransform::forwardTransform(Point2D const &point) const { return point; }
45 
46 Point2D IdentityXYTransform::reverseTransform(Point2D const &point) const { return point; }
47 
49  // note: AffineTransform constructor called with no arguments gives the identity transform
50  return AffineTransform();
51 }
52 
54  // note: AffineTransform constructor called with no arguments gives the identity transform
55  return AffineTransform();
56 }
57 }
58 }
59 }
virtual AffineTransform linearizeReverseTransform(Point2D const &point) const
default implementation; subclass may override
IdentityXYTransform & operator=(IdentityXYTransform const &)
A base class for image defects.
virtual Point2D reverseTransform(Point2D const &point) const
An affine coordinate transformation consisting of a linear transformation and an offset.
virtual std::shared_ptr< XYTransform > clone() const
returns a deep copy
afw::geom::AffineTransform AffineTransform
Definition: XYTransform.h:52
virtual Point2D forwardTransform(Point2D const &point) const
virtuals for forward and reverse transforms
Virtual base class for 2D transforms.
Definition: XYTransform.h:49
A trivial XYTransform satisfying f(x)=x.
Definition: XYTransform.h:104
virtual AffineTransform linearizeForwardTransform(Point2D const &point) const
linearized forward and reversed transforms