24 #ifndef LSST_AFW_GEOM_Span_h_INCLUDED
25 #define LSST_AFW_GEOM_Span_h_INCLUDED
30 #include "boost/serialization/nvp.hpp"
38 namespace serialization{
57 typedef boost::shared_ptr<Span>
Ptr;
58 typedef boost::shared_ptr<Span const>
ConstPtr;
121 template <
typename Archive>
122 void serialize(Archive & ar,
const unsigned int version) {
123 ar & boost::serialization::make_nvp(
"y",
_y)
124 & boost::serialization::make_nvp(
"x0",
_x0)
125 & boost::serialization::make_nvp(
"x1",
_x1);
135 #endif // LSST_AFW_GEOM_Span_h_INCLUDED
An iterator that yields Point2I and increases in the x direction.
A coordinate class intended to represent absolute positions.
int getMinX() const
Minimum x-value.
int _y
Row that Span's in.
Span(int y, int x0, int x1)
int getMaxX() const
Maximum x-value.
friend std::ostream & operator<<(std::ostream &os, Span const &span)
Stream output; delegates to toString().
A range of pixels within one row of an Image.
int getWidth() const
Return the number of pixels.
lsst::afw::detection::Footprint Footprint
boost::shared_ptr< Span const > ConstPtr
int & getX0()
Return the starting x-value.
int getEndX() const
End (exclusive) x-value.
void shift(int dx, int dy)
bool isEmpty() const
Return true if the span contains no pixels.
Iterator begin() const
Return an iterator to the first pixel in the Span.
int _x0
Starting column (inclusive)
bool operator==(Span const &other) const
boost::shared_ptr< Span > Ptr
int _x1
Ending column (inclusive)
bool contains(int x, int y) const
Point2I const getMin() const
Point corresponding to minimum x.
bool contains(int x) const
Iterator end() const
Return an iterator to one past the last pixel in the Span.
std::string toString() const
Return a string-representation of a Span.
bool contains(Point2I const &point) const
friend class boost::serialization::access
int & getX1()
Return the ending x-value.
int getY() const
Return the y-value.
int & getY()
Return the y-value.
afw::table::Key< double > b
SpanPixelIterator Iterator
An iterator over points in the Span.
bool operator<(const Span &b) const
void serialize(Archive &ar, const unsigned int version)
A coordinate class intended to represent offsets and dimensions.
int getBeginX() const
Begin (inclusive) x-value.
int getX1() const
Return the ending x-value.
bool operator!=(Span const &other) const
int getX0() const
Return the starting x-value.
Span()
Construct an empty Span with zero width at the origin.
Point2I const getMax() const
Point corresponding to maximum x.