25 #ifndef LSST_AFW_IMAGE_EXPOSURE_H
26 #define LSST_AFW_IMAGE_EXPOSURE_H
28 #include "boost/cstdint.hpp"
29 #include "boost/shared_ptr.hpp"
30 #include "boost/make_shared.hpp"
37 namespace lsst {
namespace afw {
39 namespace formatters {
40 template<
typename ImageT,
typename MaskT,
typename VarianceT>
class ExposureFormatter;
52 typedef boost::shared_ptr<Exposure>
Ptr;
53 typedef boost::shared_ptr<Exposure const>
ConstPtr;
57 unsigned int width,
unsigned int height,
118 bool const deep=
false
125 bool const deep=
false
132 template<
typename OtherPixelT>
136 lsst::daf::base::
Citizen(typeid(this)),
141 throw LSST_EXCEPT(lsst::pex::exceptions::InvalidParameterError,
142 "Exposure's converting copy constructor must make a deep copy");
254 void writeFits(std::string
const & fileName)
const;
296 fits::Fits & fitsfile, geom::Box2I const & bbox,
307 template <typename ImagePixelT, typename MaskPixelT, typename VariancePixelT>
309 MaskedImage<ImagePixelT, MaskPixelT, VariancePixelT> & mimage,
318 #endif // LSST_AFW_IMAGE_EXPOSURE_H
Filter getFilter() const
Return the Exposure's filter.
boost::uint16_t MaskPixel
MaskedImageT getMaskedImage()
Return the MaskedImage.
int getWidth() const
Return the number of columns in the image.
boost::shared_ptr< lsst::afw::cameraGeom::Detector const > getDetector() const
Return the Exposure's Detector information.
int getWidth() const
Return the Exposure's width.
static Exposure readFits(fits::MemFileManager &manager)
Read an Exposure from a FITS RAM file.
boost::shared_ptr< Exposure > Ptr
void setFilter(Filter const &filter)
Set the Exposure's filter.
A class to contain the data, WCS, and other information needed to describe an image of the sky...
void setCalib(boost::shared_ptr< Calib > calib)
Set the Exposure's Calib object.
boost::shared_ptr< PropertySet > Ptr
MaskedImageT _maskedImage
void _readFits(fits::Fits &fitsfile, geom::Box2I const &bbox, ImageOrigin origin, bool conformMasks)
Implementation of the WCS standard for a any projection.
boost::shared_ptr< ExposureInfo > _info
A simple struct that combines the two arguments that must be passed to most cfitsio routines and cont...
An integer coordinate rectangle.
table::Key< table::Array< Kernel::Pixel > > image
boost::shared_ptr< ExposureInfo > getInfo()
Get the ExposureInfo that aggregates all the non-image components. Never null.
void setDetector(boost::shared_ptr< lsst::afw::cameraGeom::Detector const > detector)
Set the Exposure's Detector information.
afw::table::PointKey< int > dimensions
boost::shared_ptr< Exposure const > ConstPtr
void writeFits(std::string const &fileName) const
Write an Exposure to a regular multi-extension FITS file.
Lifetime-management for memory that goes into FITS memory files.
geom::Box2I getBBox(ImageOrigin const origin=PARENT) const
void setXY0(geom::Point2I const &origin)
int getHeight() const
Return the Exposure's height.
float VariancePixel
! default type for Masks and MaskedImage Masks
geom::Point2I getXY0() const
Holds an integer identifier for an LSST filter.
boost::shared_ptr< lsst::afw::detection::Psf > getPsf()
Return the Exposure's Psf object.
bool hasWcs() const
Does this Exposure have a Wcs?
lsst::daf::base::PropertySet::Ptr getMetadata() const
Return flexible metadata.
#define LSST_PERSIST_FORMATTER(formatter...)
#define LSST_EXCEPT(type,...)
Citizen(const std::type_info &)
Exposure(unsigned int width, unsigned int height, boost::shared_ptr< Wcs const > wcs=boost::shared_ptr< Wcs const >())
Exposure Class Implementation for LSST: a templated framework class for creating an Exposure from a M...
MaskedImage< ImageT, MaskT, VarianceT > MaskedImageT
geom::Box2I getBBox(ImageOrigin const origin=PARENT) const
void setPsf(boost::shared_ptr< lsst::afw::detection::Psf const > psf)
Set the Exposure's Psf.
Exposure(Exposure< OtherPixelT, MaskT, VarianceT > const &rhs, const bool deep)
geom::Extent2I getDimensions() const
Return the Exposure's size.
boost::shared_ptr< Calib > getCalib()
Return the Exposure's Calib object.
Exposure< ImagePixelT, MaskPixelT, VariancePixelT >::Ptr makeExposure(MaskedImage< ImagePixelT, MaskPixelT, VariancePixelT > &mimage, boost::shared_ptr< Wcs const > wcs=boost::shared_ptr< Wcs const >())
void setWcs(boost::shared_ptr< Wcs > wcs)
bool hasPsf() const
Does this Exposure have a Psf?
Base class for all persistable classes.
Implementation of the Class MaskedImage.
Citizen is a class that should be among all LSST classes base classes, and handles basic memory manag...
A collection of all the things that make an Exposure different from a MaskedImage.
boost::shared_ptr< Wcs const > getWcs() const
A polymorphic base class for representing an image's Point Spread Function.
int getHeight() const
Return the number of rows in the image.
geom::Extent2I getDimensions() const
static Exposure readFits(std::string const &filename)
Read an Exposure from a regular FITS file.
geom::Point2I getXY0() const
void setMaskedImage(MaskedImageT &maskedImage)
Set the MaskedImage of the Exposure.
void setMetadata(lsst::daf::base::PropertySet::Ptr metadata)
MaskedImageT getMaskedImage() const
Return the MaskedImage.