LSST Applications g07dc498a13+cb17356775,g1409bbee79+cb17356775,g1a7e361dbc+cb17356775,g1fd858c14a+d1a2a640a9,g33399d78f5+fe6948661d,g35bb328faa+e55fef2c71,g3bd4b5ce2c+cac9e18807,g3c79e8cd92+2359a18b76,g43bc871e57+a58ba40925,g53246c7159+e55fef2c71,g60b5630c4e+8133a3545f,g78460c75b0+8427c4cc8f,g78619a8342+55305cb8f0,g786e29fd12+307f82e6af,g8534526c7b+8e1c6b434f,g89139ef638+cb17356775,g8b49a6ea8e+8133a3545f,g8ffcb69f3d+818ab6c36e,g9125e01d80+e55fef2c71,g97b8272a79+98425f45f6,g989de1cb63+cb17356775,g9f33ca652e+4245ceb508,gaaedd4e678+cb17356775,gabe3b4be73+9c0c3c7524,gb1101e3267+3e5ef1d639,gb58c049af0+28045f66fd,gc1fe0db326+8133a3545f,gca43fec769+e55fef2c71,gcf25f946ba+fe6948661d,gd397e13551+64039f84ea,gd6cbbdb0b4+f6e5445f66,gde0f65d7ad+7eb368c542,ge278dab8ac+b4c2c8faf7,geab183fbe5+8133a3545f,gecb8035dfe+1f480bec5e,gefa07fa684+e7bc33f3ea,gf58bf46354+e55fef2c71,gfe7187db8c+e55afb4430,w.2025.03
LSST Data Management Base Package
Loading...
Searching...
No Matches
lsst::afw::image::MaskedImage< typename, typename, typename >::const_MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator > Class Template Reference

A const locator for the MaskedImage. More...

#include <MaskedImage.h>

Inheritance diagram for lsst::afw::image::MaskedImage< typename, typename, typename >::const_MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator >:
lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< detail::const_locator_type< ImageLocator >::type, detail::const_locator_type< MaskLocator >::type, detail::const_locator_type< VarianceLocator >::type, ConstReference >

Public Types

using IMVCachedLocation
 
using x_iterator
 An x_iterator that provides a view of the xy_locator (i.e. advancing one advances the other)
 
using y_iterator
 A y_iterator that provides a view of the xy_locator (i.e. advancing one advances the other)
 
using PixelTVec
 

Public Member Functions

 const_MaskedImageLocator (MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator > const &iter)
 
Pixel operator* ()
 Dereference a locator, returning a Pixel.
 
Pixel operator() (int x, int y)
 Dereference a locator, returning a Pixel offset by (x, y) from the locator.
 
Pixel operator[] (cached_location_t const &cached_loc)
 Dereference a locator, returning a Pixel offset by the amount set when we created the cached_location_t
 
x_iterator x ()
 Return an iterator that can be used to move (or dereference) a locator.
 
y_iterator y ()
 Return an iterator that can be used to move (or dereference) a locator.
 
cached_location_t cache_location (int x, int y) const
 Create a cached_location_t offset by (x, y) from locator.
 
ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type apply_IMV (cached_location_t const &cached_loc)
 
ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type apply_IMV ()
 
ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type apply_IMV (int x, int y)
 
ConstReference< ImagePixelT >::type image (cached_location_t const &cached_loc)
 Return a reference to the image at the offset set when we created the cached_location_t
 
ConstReference< ImagePixelT >::type image ()
 Return a reference to the image at the current position of the locator.
 
ConstReference< ImagePixelT >::type image (int x, int y)
 Return a reference to the image offset by (x, y) from the current position of the locator.
 
ConstReference< MaskPixelT >::type mask (cached_location_t const &cached_loc)
 Return a reference to the mask at the offset set when we created the cached_location_t
 
ConstReference< MaskPixelT >::type mask ()
 Return a reference to the mask at the current position of the locator.
 
ConstReference< MaskPixelT >::type mask (int x, int y)
 Return a reference to the mask offset by (x, y) from the current position of the locator.
 
ConstReference< VariancePixelT >::type variance (cached_location_t const &cached_loc)
 Return a reference to the variance at the offset set when we created the cached_location_t
 
ConstReference< VariancePixelT >::type variance ()
 Return a reference to the variance at the current position of the locator.
 
ConstReference< VariancePixelT >::type variance (int x, int y)
 Return a reference to the variance offset by (x, y) from the current position of the locator.
 
bool operator== (MaskedImageLocatorBase const &rhs)
 Return true iff two locators are equal.
 
bool operator!= (MaskedImageLocatorBase const &rhs)
 Return true iff two locators are not equal.
 
bool operator< (MaskedImageLocatorBase const &rhs)
 Return true iff lhs is less than rhs.
 
MaskedImageLocatorBaseoperator+= (pair2I const &p)
 Increment the locator's x and y positions by p
 
MaskedImageLocatorBaseoperator+= (detail::difference_type p)
 Increment the locator's x and y positions by p
 
IMVLocator const & getLoc () const
 

Protected Attributes

IMVLocator _loc
 

Detailed Description

template<typename, typename, typename>
template<typename ImageLocator, typename MaskLocator, typename VarianceLocator>
class lsst::afw::image::MaskedImage< typename, typename, typename >::const_MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator >

A const locator for the MaskedImage.

A const locator for a MaskedImage.

Definition at line 509 of file MaskedImage.h.

Member Typedef Documentation

◆ IMVCachedLocation

using lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::IMVCachedLocation
inherited

Definition at line 348 of file MaskedImage.h.

◆ PixelTVec

using lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::PixelTVec
inherited

Definition at line 415 of file MaskedImage.h.

◆ x_iterator

using lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::x_iterator
inherited

An x_iterator that provides a view of the xy_locator (i.e. advancing one advances the other)

Definition at line 350 of file MaskedImage.h.

◆ y_iterator

using lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::y_iterator
inherited

A y_iterator that provides a view of the xy_locator (i.e. advancing one advances the other)

Definition at line 352 of file MaskedImage.h.

Constructor & Destructor Documentation

◆ const_MaskedImageLocator()

template<typename , typename , typename >
template<typename ImageLocator , typename MaskLocator , typename VarianceLocator >
lsst::afw::image::MaskedImage< typename, typename, typename >::const_MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator >::const_MaskedImageLocator ( MaskedImageLocator< ImageLocator, MaskLocator, VarianceLocator > const & iter)
inline

Definition at line 521 of file MaskedImage.h.

522 : MaskedImageLocatorBase_t(const_ImageLocator(iter.getLoc().template get<0>()),
523 const_MaskLocator(iter.getLoc().template get<1>()),
524 const_VarianceLocator(iter.getLoc().template get<2>())) {
525 ;
526 }

Member Function Documentation

◆ apply_IMV() [1/3]

ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::apply_IMV ( )
inlineinherited

◆ apply_IMV() [2/3]

ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::apply_IMV ( cached_location_t const & cached_loc)
inlineinherited

Definition at line 418 of file MaskedImage.h.

419 {
420 return _loc.template get<N::value>()[cached_loc._imv.template get<N::value>()][0];
421 }

◆ apply_IMV() [3/3]

ConstReference< typenameboost::mpl::at< PixelTVec, N >::type >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::apply_IMV ( int x,
int y )
inlineinherited

Definition at line 429 of file MaskedImage.h.

429 {
430 return _loc.template get<N::value>()(x, y)[0];
431 }
int y
Definition SpanSet.cc:48

◆ cache_location()

cached_location_t lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::cache_location ( int x,
int y ) const
inlineinherited

Create a cached_location_t offset by (x, y) from locator.

Definition at line 409 of file MaskedImage.h.

409{ return cached_location_t(_loc, x, y); }

◆ getLoc()

IMVLocator const & lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::getLoc ( ) const
inlineinherited

Definition at line 491 of file MaskedImage.h.

491{ return _loc; }

◆ image() [1/3]

ConstReference< ImagePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::image ( )
inlineinherited

Return a reference to the image at the current position of the locator.

Definition at line 440 of file MaskedImage.h.

440{ return apply_IMV<boost::mpl::int_<0>>(); }

◆ image() [2/3]

ConstReference< ImagePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::image ( cached_location_t const & cached_loc)
inlineinherited

Return a reference to the image at the offset set when we created the cached_location_t

Definition at line 436 of file MaskedImage.h.

436 {
437 return apply_IMV<boost::mpl::int_<0>>(cached_loc);
438 }

◆ image() [3/3]

ConstReference< ImagePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::image ( int x,
int y )
inlineinherited

Return a reference to the image offset by (x, y) from the current position of the locator.

Definition at line 442 of file MaskedImage.h.

442{ return apply_IMV<boost::mpl::int_<0>>(x, y); }

◆ mask() [1/3]

ConstReference< MaskPixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::mask ( )
inlineinherited

Return a reference to the mask at the current position of the locator.

Definition at line 449 of file MaskedImage.h.

449{ return apply_IMV<boost::mpl::int_<1>>(); }

◆ mask() [2/3]

ConstReference< MaskPixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::mask ( cached_location_t const & cached_loc)
inlineinherited

Return a reference to the mask at the offset set when we created the cached_location_t

Definition at line 445 of file MaskedImage.h.

445 {
446 return apply_IMV<boost::mpl::int_<1>>(cached_loc);
447 }

◆ mask() [3/3]

ConstReference< MaskPixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::mask ( int x,
int y )
inlineinherited

Return a reference to the mask offset by (x, y) from the current position of the locator.

Definition at line 451 of file MaskedImage.h.

451{ return apply_IMV<boost::mpl::int_<1>>(x, y); }

◆ operator!=()

bool lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator!= ( MaskedImageLocatorBase< detail::const_locator_type< ImageLocator >::type, detail::const_locator_type< MaskLocator >::type, detail::const_locator_type< VarianceLocator >::type, ConstReference > const & rhs)
inlineinherited

Return true iff two locators are not equal.

Definition at line 469 of file MaskedImage.h.

469{ return !(*this == rhs); }

◆ operator()()

Pixel lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator() ( int x,
int y )
inlineinherited

Dereference a locator, returning a Pixel offset by (x, y) from the locator.

Definition at line 384 of file MaskedImage.h.

384 {
385 return Pixel(_loc.template get<0>()(x, y)[0], _loc.template get<1>()(x, y)[0],
386 _loc.template get<2>()(x, y)[0]);
387 }
float Pixel
Typedefs to be used for pixel values.
Definition common.h:37

◆ operator*()

Pixel lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator* ( )
inlineinherited

Dereference a locator, returning a Pixel.

Definition at line 378 of file MaskedImage.h.

378 {
379 return Pixel(_loc.template get<0>().x()[0][0], _loc.template get<1>().x()[0][0],
380 _loc.template get<2>().x()[0][0]);
381 }

◆ operator+=() [1/2]

MaskedImageLocatorBase & lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator+= ( detail::difference_type p)
inlineinherited

Increment the locator's x and y positions by p

Definition at line 481 of file MaskedImage.h.

481 {
482 _loc.template get<0>() += p;
483 _loc.template get<1>() += p;
484 _loc.template get<2>() += p;
485
486 return *this;
487 }

◆ operator+=() [2/2]

MaskedImageLocatorBase & lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator+= ( pair2I const & p)
inlineinherited

Increment the locator's x and y positions by p

Definition at line 476 of file MaskedImage.h.

◆ operator<()

bool lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator< ( MaskedImageLocatorBase< detail::const_locator_type< ImageLocator >::type, detail::const_locator_type< MaskLocator >::type, detail::const_locator_type< VarianceLocator >::type, ConstReference > const & rhs)
inlineinherited

Return true iff lhs is less than rhs.

Definition at line 471 of file MaskedImage.h.

471 {
472 return _loc.template get<0>() < rhs._loc.template get<0>();
473 }

◆ operator==()

bool lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator== ( MaskedImageLocatorBase< detail::const_locator_type< ImageLocator >::type, detail::const_locator_type< MaskLocator >::type, detail::const_locator_type< VarianceLocator >::type, ConstReference > const & rhs)
inlineinherited

Return true iff two locators are equal.

Definition at line 465 of file MaskedImage.h.

465 {
466 return _loc.template get<0>() == rhs._loc.template get<0>();
467 }

◆ operator[]()

Pixel lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::operator[] ( cached_location_t const & cached_loc)
inlineinherited

Dereference a locator, returning a Pixel offset by the amount set when we created the cached_location_t

Definition at line 391 of file MaskedImage.h.

391 {
392 return Pixel(_loc.template get<0>()[cached_loc._imv.template get<0>()][0],
393 _loc.template get<1>()[cached_loc._imv.template get<1>()][0],
394 _loc.template get<2>()[cached_loc._imv.template get<2>()][0]);
395 }

◆ variance() [1/3]

ConstReference< VariancePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::variance ( )
inlineinherited

Return a reference to the variance at the current position of the locator.

Definition at line 458 of file MaskedImage.h.

458{ return apply_IMV<boost::mpl::int_<2>>(); }

◆ variance() [2/3]

ConstReference< VariancePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::variance ( cached_location_t const & cached_loc)
inlineinherited

Return a reference to the variance at the offset set when we created the cached_location_t

Definition at line 454 of file MaskedImage.h.

454 {
455 return apply_IMV<boost::mpl::int_<2>>(cached_loc);
456 }

◆ variance() [3/3]

ConstReference< VariancePixelT >::type lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::variance ( int x,
int y )
inlineinherited

Return a reference to the variance offset by (x, y) from the current position of the locator.

Definition at line 460 of file MaskedImage.h.

460 {
461 return apply_IMV<boost::mpl::int_<2>>(x, y);
462 }

◆ x()

x_iterator lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::x ( )
inlineinherited

Return an iterator that can be used to move (or dereference) a locator.

Note
this x_locator is xy_locator::x_locator, not MaskedImage::x_locator

Definition at line 400 of file MaskedImage.h.

◆ y()

y_iterator lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::y ( )
inlineinherited

Return an iterator that can be used to move (or dereference) a locator.

Note
this y_locator is xy_locator::y_locator, not MaskedImage::y_locator

Definition at line 406 of file MaskedImage.h.

Member Data Documentation

◆ _loc

IMVLocator lsst::afw::image::MaskedImage< typename, typename, typename >::MaskedImageLocatorBase< ImageLocator, MaskLocator, VarianceLocator, ConstReference >::_loc
protectedinherited

Definition at line 494 of file MaskedImage.h.


The documentation for this class was generated from the following file: