add vtk solids
This commit is contained in:
@@ -151,6 +151,7 @@ TessellatedSolid::TessellatedSolid(const char *name)
|
||||
}
|
||||
|
||||
void TessellatedSolid::SetMesh(TriangleMesh &mesh) {
|
||||
this->m_Mesh = mesh;
|
||||
G4TessellatedSolid *ts = this->m_Solid;
|
||||
for (int i = 0; i < mesh.Triangles().size(); ++i) {
|
||||
const Vector3i &trg = mesh.Triangles().at(i);
|
||||
@@ -165,6 +166,9 @@ void TessellatedSolid::SetMesh(TriangleMesh &mesh) {
|
||||
}
|
||||
}
|
||||
|
||||
void TessellatedSolid::Update() {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -93,11 +93,14 @@ public:
|
||||
void SetMesh(TriangleMesh &mesh);
|
||||
uLibGetMacro(Solid, G4TessellatedSolid *)
|
||||
virtual G4VSolid* GetG4Solid() const override { return (G4VSolid*)m_Solid; }
|
||||
|
||||
const TriangleMesh& GetMesh() const { return m_Mesh; }
|
||||
|
||||
public slots:
|
||||
void Update();
|
||||
|
||||
private :
|
||||
TriangleMesh m_Mesh;
|
||||
G4TessellatedSolid *m_Solid;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user