15 #ifndef BORNAGAIN_GUI_VIEW_REALSPACE_REALSPACEBUILDERUTILS_H
16 #define BORNAGAIN_GUI_VIEW_REALSPACE_REALSPACEBUILDERUTILS_H
18 #include "Sample/Scattering/Rotations.h"
30 class ParticleComposition;
31 class ParticleCoreShell;
35 class Interference2DParaCrystal;
52 BuilderUtils(std::function<QColor(
const QString&)> fnColorFromMaterialName);
58 const std::vector<std::vector<double>>& lattice_positions,
59 const std::vector<Particle3DContainer>& particle3DContainer_vector,
70 const R3& origin = R3(0, 0, 0));
76 const ParticleCoreShell& particleCoreShell,
77 const R3& origin = R3(0, 0, 0));
84 const QVector3D& origin = {});
87 double total_abundance = 1.0,
88 const QVector3D& origin = {});
91 double total_abundance = 1.0,
92 const QVector3D& origin = {});
96 double total_abundance = 1.0,
const QVector3D& origin = {});
99 double total_abundance = 1.0,
100 const QVector3D& origin = {});
GUI::RealSpace::Vector3D implementParticleRotationfromIRotation(const IRotation *&rotation)
Particle3DContainer mesoCrystal3DContainer(const MesoCrystalItem &mesoCrystalItem, double total_abundance=1.0, const QVector3D &origin={})
void applyParticleCoreShellTransformations(const Particle &particle, GUI::RealSpace::Particles::Particle &particle3D, const ParticleCoreShell &particleCoreShell, const R3 &origin=R3(0, 0, 0))
Apply transformations (translation, rotation) to a particle (core/shell) in a ParticleCoreShell.
void applyParticleColor(const Particle &particle, GUI::RealSpace::Particles::Particle &particle3D, double alpha=1)
Particle3DContainer particleCoreShell3DContainer(const ParticleCoreShell &particleCoreShell, double total_abundance=1.0, const QVector3D &origin={})
std::vector< Particle3DContainer > particle3DContainerVector(const ParticleLayoutItem &layoutItem, const QVector3D &origin={})
QVector< double > computeCumulativeAbundances(const ParticleLayoutItem &layoutItem)
BuilderUtils(std::function< QColor(const QString &)> fnColorFromMaterialName)
std::function< QColor(const QString &)> m_fnColorFromMaterialName
void populateParticlesAtLatticePositions(const std::vector< std::vector< double >> &lattice_positions, const std::vector< Particle3DContainer > &particle3DContainer_vector, GUI::RealSpace::Model *model, const SceneGeometry &sceneGeometry, const RealSpaceBuilder *builder3D)
void applyParticleTransformations(const Particle &particle, GUI::RealSpace::Particles::Particle &particle3D, const R3 &origin=R3(0, 0, 0))
Apply transformations (translation, rotation) to a 3D Particle or to a particle belonging to a Partic...
Particle3DContainer singleParticle3DContainer(const Particle &particle, double total_abundance=1.0, const QVector3D &origin={})
Particle3DContainer particleComposition3DContainer(const ParticleComposition &particleComposition3DContainer, double total_abundance=1.0, const QVector3D &origin={})
Base class for a GUI data item.
Size and thickness information of layers.