From 50f28dc63177ec54e9ab9f0afa9af86aba3eecec Mon Sep 17 00:00:00 2001 From: Bernd Hahnebach Date: Tue, 13 Mar 2018 23:35:58 +0100 Subject: [PATCH] FEM: vtk tools, deactivate penta6, hexa8 and hexa20 since they will kill FreeCAD --- src/Mod/Fem/App/FemVTKTools.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Mod/Fem/App/FemVTKTools.cpp b/src/Mod/Fem/App/FemVTKTools.cpp index ec6d14cb07..fd7cf983c1 100644 --- a/src/Mod/Fem/App/FemVTKTools.cpp +++ b/src/Mod/Fem/App/FemVTKTools.cpp @@ -323,6 +323,7 @@ void exportFemMeshCells(vtkSmartPointer grid, const SMDS_Vo pyramidArray->InsertNextCell(cell); } + /* // penta6 and hexa8 as well has hexa20 make FreeCAD crash else if (aVol->NbNodes() == 6) { vtkSmartPointer cell = vtkSmartPointer::New(); cell->GetPointIds()->SetId(0, aVol->GetNode(0)->GetID()-1); @@ -347,6 +348,7 @@ void exportFemMeshCells(vtkSmartPointer grid, const SMDS_Vo hexaArray->InsertNextCell(cell); } + */ else if ( aVol->NbNodes() == 10) { // quadratic tetrahedra vtkSmartPointer tetra = vtkSmartPointer::New(); @@ -356,13 +358,15 @@ void exportFemMeshCells(vtkSmartPointer grid, const SMDS_Vo quadTetraArray->InsertNextCell(tetra); } - else if (aVol->NbNodes() == 20) { // not tested, no sure about vertex sequence + /* + else if (aVol->NbNodes() == 20) { // not tested, no sure about vertex sequence vtkSmartPointer cell= vtkSmartPointer::New(); for(int i=0; i<20; i++){ cell->GetPointIds()->SetId(i, aVol->GetNode(i)->GetID()-1); } quadHexaArray->InsertNextCell(cell); } + */ else { throw std::runtime_error("Volume not yet supported by FreeCADs VTK mesh builder\n"); }