23 #if !defined(LSST_DETECTION_FOOTPRINT_H)
24 #define LSST_DETECTION_FOOTPRINT_H
36 #include <boost/cstdint.hpp>
37 #include <boost/shared_ptr.hpp>
50 namespace serialization{
55 using boost::serialization::make_nvp;
78 typedef boost::shared_ptr<Footprint>
Ptr;
79 typedef boost::shared_ptr<const Footprint>
ConstPtr;
115 virtual bool isHeavy()
const {
return false; }
161 const Span&
addSpan(
const int y,
const int x0,
const int x1);
165 const Span&
addSpan(Span
const& span);
169 const Span&
addSpan(Span
const& span,
int dx,
int dy);
211 template<
typename PixelT>
233 template<
typename PixelT>
235 boost::uint64_t
const id,
253 template<
typename PixelT>
255 boost::uint64_t
const id,
256 bool const overwriteId,
long const idMask,
257 typename std::set<boost::uint64_t> *oldIds,
274 template <
typename MaskPixelT>
277 MaskPixelT bitmask=~0x0
292 geom::Box2I const & region,
316 template <
typename Archive>
317 void serialize(Archive & ar,
const unsigned int version);
393 bool left,
bool right,
bool up,
bool down);
408 template<typename ImageT>
411 typename ImageT::Pixel const value);
418 template<typename ImageT>
421 typename ImageT::Pixel const value);
428 template<typename ImageT>
431 typename ImageT::Pixel const value);
438 template<typename MaskT>
441 MaskT const bitmask);
450 template<typename MaskT>
453 MaskT const bitmask);
462 template <typename ImageOrMaskedImageT>
464 PTR(ImageOrMaskedImageT) const input,
465 PTR(ImageOrMaskedImageT) output);
473 template<typename MaskT>
476 MaskT const bitmask);
483 template<typename MaskT>
486 MaskT const bitmask);
502 template<typename MaskT>
504 typename image::Mask<MaskT>::Ptr const& mask,
505 MaskT const bitmask);
An ellipse core with quadrupole moments as parameters.
void nearestFootprint(std::vector< boost::shared_ptr< Footprint >> const &foots, lsst::afw::image::Image< boost::uint16_t >::Ptr argmin, lsst::afw::image::Image< boost::uint16_t >::Ptr dist)
An include file to include the header files for lsst::afw::geom.
Public header class for ellipse library.
A custom container class for records, based on std::vector.
A range of pixels within one row of an Image.
boost::shared_ptr< Footprint > footprintAndMask(boost::shared_ptr< Footprint > const &foot, typename image::Mask< MaskT >::Ptr const &mask, MaskT const bitmask)
Return a Footprint that's the intersection of a Footprint with a Mask.
Implementation of the WCS standard for a any projection.
An integer coordinate rectangle.
table::Key< table::Array< Kernel::Pixel > > image
A base class for objects that can be persisted via afw::table::io Archive classes.
boost::shared_ptr< Footprint > shrinkFootprint(Footprint const &foot, int nGrow, bool isotropic)
boost::shared_ptr< Footprint > growFootprint(Footprint const &foot, int nGrow, bool isotropic=true)
Represent a 2-dimensional array of bitmask pixels.
An ellipse defined by an arbitrary BaseCore and a center point.
boost::shared_ptr< Image< PixelT > > Ptr
MaskT clearMaskFromFootprint(lsst::afw::image::Mask< MaskT > *mask, Footprint const &footprint, MaskT const bitmask)
(AND ~bitmask) all the Mask's pixels that are in the Footprint; that is, set to zero in the Mask-inte...
ImageT::Pixel setImageFromFootprint(ImageT *image, Footprint const &footprint, typename ImageT::Pixel const value)
Set all image pixels in a Footprint to a given value.
Support for peaks in images.
std::vector< lsst::afw::geom::Box2I > footprintToBBoxList(Footprint const &foot)
MaskT setMaskFromFootprint(lsst::afw::image::Mask< MaskT > *mask, Footprint const &footprint, MaskT const bitmask)
OR bitmask into all the Mask's pixels that are in the Footprint.
io::OutputArchiveHandle OutputArchiveHandle
Implementation of the Class MaskedImage.
Citizen is a class that should be among all LSST classes base classes, and handles basic memory manag...
boost::shared_ptr< Footprint > mergeFootprints(Footprint const &foot1, Footprint const &foot2)
A CRTP facade class for subclasses of Persistable.
A class to represent a 2-dimensional array of pixels.
void copyWithinFootprint(Footprint const &foot, boost::shared_ptr< ImageOrMaskedImageT > const input, boost::shared_ptr< ImageOrMaskedImageT > output)
ImageT::Pixel setImageFromFootprintList(ImageT *image, boost::shared_ptr< std::vector< boost::shared_ptr< Footprint >> const > footprints, typename ImageT::Pixel const value)
Set all image pixels in a set of Footprints to a given value.
MaskT setMaskFromFootprintList(lsst::afw::image::Mask< MaskT > *mask, std::vector< boost::shared_ptr< Footprint >> const &footprints, MaskT const bitmask)
OR bitmask into all the Mask's pixels which are in the set of Footprints.