A 2D coordinate representing the center of a plane figure. More...
#include <centroid.h>
Public Member Functions | |
| Centroid (std::shared_ptr< CentroidData > data) | |
| Centroid (double x=0, double y=0) | |
| void | convolve (const Centroid &cen) |
| Convolve this with another centroid. | |
| const CentroidData & | get_data () const |
| Get this centroid's data. | |
| double | get_x () const |
| Get the x value. | |
| std::array< double, 2 > | get_xy () const |
| Get the x and y values. | |
| double | get_y () const |
| Get the y value. | |
| std::shared_ptr< Centroid > | make_convolution (const Centroid &cen) const |
| Return the convolution of this with another centroid. | |
| std::unique_ptr< Centroid > | make_convolution_uniq (const Centroid &cen) const |
| Same as make_convolution(), but returning a unique_ptr. | |
| void | set_x (double x) |
| void | set_xy (const std::array< double, 2 > &xy) |
| void | set_y (double y) |
| std::string | repr (bool name_keywords=false, std::string_view namespace_separator=Object::CC_NAMESPACE_SEPARATOR) const override |
| std::string | str () const override |
| Return a brief, human-readable string representation of this. | |
| bool | operator== (const Centroid &other) const |
| bool | operator!= (const Centroid &other) const |
Additional Inherited Members | |
Static Public Member Functions inherited from lsst::gauss2d::Object | |
| static std::string_view | null_str (const std::string_view &namespace_separator) |
Static Public Attributes inherited from lsst::gauss2d::Object | |
| static constexpr std::string_view | CC_NAMESPACE_SEPARATOR = "::" |
| The C++ namespace separator. | |
| static constexpr std::string_view | NULL_STR_GENERAL = "None" |
| static constexpr std::string_view | PY_NAMESPACE_SEPARATOR = "." |
A 2D coordinate representing the center of a plane figure.
This is a centroid in a 2D coordinate system, generally used for ellipses in this package. Storage is implemented in CentroidData.
| data | The centroid data |
| void lsst::gauss2d::Centroid::convolve | ( | const Centroid & | cen | ) |
Convolve this with another centroid.
Convolution simply adds the value of the other centroid to this.
| cen | The centroid to convolve with |
Return the convolution of this with another centroid.
Convolution simply adds the values of both centroids together
| cen | The centroid to convolve with |
|
overridevirtual |
Return a full, callable string representation of this.
| name_keywords | Whether to prefix arguments with "{name}=", where name is the arg name in the header (as with keyword arguments in Python). |
| namespace_separator | The string to use to delimit namespaces, i.e. :: in C++ and . in Python. |
Implements lsst::gauss2d::Object.
|
overridevirtual |
Return a brief, human-readable string representation of this.
Implements lsst::gauss2d::Object.