BornAgain
1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
|
Holds precalculated information for faster DiffuseElement generation.
Definition at line 29 of file DetectorContext.h.
Public Member Functions | |
DetectorContext (const DetectorContext &other)=delete | |
DetectorContext (const IDetector *detector) | |
std::unique_ptr< IPixel > | createPixel (size_t element_index) const |
Creates pixel for given element index. Element index is sequential index in a vector of DiffuseElements. Corresponds to sequence of detector bins inside ROI and outside of masked areas. More... | |
size_t | detectorIndex (size_t element_index) const |
size_t | numberOfElements () const |
DetectorContext & | operator= (const DetectorContext &other)=delete |
Private Member Functions | |
void | setup_context (const IDetector *detector) |
Private Attributes | |
std::vector< size_t > | m_active_indices |
All unmasked pixels inside ROI. More... | |
SpinMatrix | m_analyzer_operator |
std::vector< std::unique_ptr< IPixel > > | m_pixels |
DetectorContext::DetectorContext | ( | const IDetector * | detector | ) |
Definition at line 18 of file DetectorContext.cpp.
References setup_context().
|
delete |
std::unique_ptr< IPixel > DetectorContext::createPixel | ( | size_t | element_index | ) | const |
Creates pixel for given element index. Element index is sequential index in a vector of DiffuseElements. Corresponds to sequence of detector bins inside ROI and outside of masked areas.
Definition at line 32 of file DetectorContext.cpp.
References m_pixels.
size_t DetectorContext::detectorIndex | ( | size_t | element_index | ) | const |
Definition at line 37 of file DetectorContext.cpp.
References m_active_indices.
size_t DetectorContext::numberOfElements | ( | ) | const |
Definition at line 23 of file DetectorContext.cpp.
References m_active_indices.
|
delete |
|
private |
Definition at line 42 of file DetectorContext.cpp.
References IDetector::active_indices(), IDetector::analyzer(), IDetector::createPixel(), m_active_indices, m_analyzer_operator, m_pixels, and PolFilter::matrix().
Referenced by DetectorContext().
|
private |
All unmasked pixels inside ROI.
Definition at line 47 of file DetectorContext.h.
Referenced by detectorIndex(), numberOfElements(), and setup_context().
|
private |
Definition at line 45 of file DetectorContext.h.
Referenced by setup_context().
|
private |
Definition at line 46 of file DetectorContext.h.
Referenced by createPixel(), and setup_context().