|
Mantid
|
CalibrationHelpers : This contains helper methods to move source, sample and detector positions/rotations for an instrument according to some calibration information. More...
Functions | |
| MANTID_CRYSTAL_DLL void | adjustBankPositionsAndSizes (const std::vector< std::string > &bankNames, const Instrument &newInstrument, const V3D &pos, const Quat &rot, const double detWScale, const double detHtScale, ComponentInfo &componentInfo) |
| Updates ComponentInfo for newInstrument to reflect the changes in the associated panel information. More... | |
| MANTID_CRYSTAL_DLL void | adjustUpSampleAndSourcePositions (const double L0, const V3D &newSampPos, ComponentInfo &componentInfo) |
| Updates the ComponentInfo for the workspace containing newInstrument to reflect the position of the source. More... | |
CalibrationHelpers : This contains helper methods to move source, sample and detector positions/rotations for an instrument according to some calibration information.
| void Mantid::Crystal::CalibrationHelpers::adjustBankPositionsAndSizes | ( | const std::vector< std::string > & | bankNames, |
| const Instrument & | newInstrument, | ||
| const V3D & | pos, | ||
| const Quat & | rot, | ||
| const double | detWScale, | ||
| const double | detHtScale, | ||
| ComponentInfo & | componentInfo | ||
| ) |
Updates ComponentInfo for newInstrument to reflect the changes in the associated panel information.
| bankNames | The names of the banks (panels) that will be updated |
| newInstrument | The instrument whose parameter map will be changed to reflect the new values below |
| pos | The quantity to be added to the current relative position, from old NewInstrument, of the banks in bankNames. |
| rot | The quantity to be added to the current relative rotations, from old NewInstrument, of the banks in bankNames. |
| detWScale | The factor to multiply the current detector width, from old NewInstrument, by to get the new detector width for the banks in bankNames. |
| detHtScale | The factor to multiply the current detector height, from old NewInstrument, by to get the new detector height for the banks in bankNames. |
| componentInfo | ComponentInfo object for the modifications |
Definition at line 63 of file CalibrationHelpers.cpp.
References Mantid::API::applyRectangularDetectorScaleToComponentInfo(), Mantid::Geometry::CompAssembly::getComponentByName(), Mantid::Geometry::Instrument::getParameterMap(), Mantid::Kernel::Quat::getRotation(), Mantid::Geometry::ComponentInfo::indexOf(), Mantid::Geometry::ComponentInfo::setPosition(), and Mantid::Geometry::ComponentInfo::setRotation().
| void Mantid::Crystal::CalibrationHelpers::adjustUpSampleAndSourcePositions | ( | const double | L0, |
| const V3D & | newSampPos, | ||
| ComponentInfo & | componentInfo | ||
| ) |
Updates the ComponentInfo for the workspace containing newInstrument to reflect the position of the source.
reflect the new source position
| L0 | The new distance from source to sample (should be positive) |
| newSampPos | The relative shift for the new sample position |
| componentInfo | ComponentInfo for the workspace being updated |
Definition at line 26 of file CalibrationHelpers.cpp.
References Mantid::Geometry::ComponentInfo::l1(), Mantid::Geometry::ComponentInfo::sample(), Mantid::Geometry::ComponentInfo::samplePosition(), Mantid::Geometry::ComponentInfo::setPosition(), Mantid::Geometry::ComponentInfo::source(), and Mantid::Geometry::ComponentInfo::sourcePosition().
Referenced by Mantid::Crystal::OptimizeCrystalPlacement::exec(), and Mantid::Crystal::SetCrystalLocation::exec().