From 45472803e381ef0f97ee0066240c61f7cc81e1b2 Mon Sep 17 00:00:00 2001 From: apo Date: Thu, 25 Aug 2005 11:10:14 +0000 Subject: [PATCH] To implement ID's mapping --- src/CONVERTOR/VISU_Convertor_impl.hxx | 8 ++++++++ src/CONVERTOR/VISU_MedConvertor.cxx | 4 ++++ src/CONVERTOR/VISU_MedConvertor.hxx | 16 +++++++++++++++- 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/src/CONVERTOR/VISU_Convertor_impl.hxx b/src/CONVERTOR/VISU_Convertor_impl.hxx index 623f3680..5d513381 100644 --- a/src/CONVERTOR/VISU_Convertor_impl.hxx +++ b/src/CONVERTOR/VISU_Convertor_impl.hxx @@ -193,6 +193,14 @@ namespace VISU struct TGaussSubMeshImpl: virtual TGaussSubMesh, virtual TSource { TGaussSubMeshImpl(); + + virtual + vtkIdType + GetObjID(vtkIdType theID) const + { + return theID; + } + TPointCoords myPointCoords; ESubMeshStatus myStatus; }; diff --git a/src/CONVERTOR/VISU_MedConvertor.cxx b/src/CONVERTOR/VISU_MedConvertor.cxx index e390193a..43b842de 100644 --- a/src/CONVERTOR/VISU_MedConvertor.cxx +++ b/src/CONVERTOR/VISU_MedConvertor.cxx @@ -1244,6 +1244,10 @@ LoadGaussMesh(const MED::PWrapper& theMed, aMEntity, aMGeom); + aGaussSubMesh->myIsElemNum = aCellInfo->IsElemNum(); + if(aGaussSubMesh->myIsElemNum) + aGaussSubMesh->myElemNum = aCellInfo->myElemNum; + std::string aName; MED::TGaussCoord aGaussCoord; bool anIsGaussCoord3D = false; diff --git a/src/CONVERTOR/VISU_MedConvertor.hxx b/src/CONVERTOR/VISU_MedConvertor.hxx index 5bc6ff06..bb187c23 100644 --- a/src/CONVERTOR/VISU_MedConvertor.hxx +++ b/src/CONVERTOR/VISU_MedConvertor.hxx @@ -12,6 +12,7 @@ #include "VISU_Convertor_impl.hxx" #include "MED_Common.hxx" +#include "MED_Structures.hxx" #include @@ -50,7 +51,20 @@ namespace VISU //--------------------------------------------------------------- struct TMEDGaussSubMesh: virtual TGaussSubMeshImpl - {}; + { + MED::EBooleen myIsElemNum; + MED::TElemNum myElemNum; + + virtual + vtkIdType + GetObjID(vtkIdType theID) const + { + if(myIsElemNum) + return myElemNum[theID]; + else + return theID; + } + }; typedef SharedPtr PMEDGaussSubMesh; -- 2.39.2