#include "MED_Structures.hxx"
#include "MED_Utilities.hxx"
-
+#include <string>
using namespace std;
using namespace MED;
static int MYDEBUG = 0;
#endif
+#if defined __GNUC__
+ #if __GNUC__ == 2
+ #define __GNUC_2__
+ #endif
+#endif
//---------------------------------------------------------------
string MED::GetString(med_int theId, med_int theStep,
EXCEPTION(runtime_error,"myCoord.size() != myNbElem*theMeshInfo->myDim");
for(med_int anId = 0; anId < theMeshInfo->myDim; anId++){
+#if defined __GNUC_2__
+ const string& aVal = theCoordNames[anId];
+#else
const string& aVal = theCoordNames.at(anId);
+#endif
+
SetCoordName(anId,aVal);
}
for(med_int anId = 0; anId < theMeshInfo->myDim; anId++){
+#if defined __GNUC_2__
+ const string& aVal = theCoordUnits[anId];
+#else
const string& aVal = theCoordUnits.at(anId);
+#endif
SetCoordUnit(anId,aVal);
}
}
using namespace std;
+#if defined __GNUC__
+ #if __GNUC__ == 2
+ #define __GNUC_2__
+ #endif
+#endif
+
int SALOME_POINT_SIZE = 3;
void SALOME_Actor::SetMapper(vtkMapper* theMapper){
if(theMapper){
int anId = 0;
+#if defined __GNUC_2__
+ myPassFilter[anId]->SetInput(theMapper->GetInput());
+#else
myPassFilter.at(anId)->SetInput(theMapper->GetInput());
+#endif
myGeomFilter->SetStoreMapping(myStoreMapping);
+#if defined __GNUC_2__
+ myGeomFilter->SetInput(myPassFilter[anId]->GetOutput());
+#else
myGeomFilter->SetInput(myPassFilter.at(anId)->GetOutput());
+#endif
anId++;
+
+#if defined __GNUC_2__
+ myPassFilter[anId]->SetInput(myGeomFilter->GetOutput());
+ myPassFilter[anId+1]->SetInput(myPassFilter[anId]->GetOutput());
+#else
myPassFilter.at(anId)->SetInput(myGeomFilter->GetOutput());
myPassFilter.at(anId+1)->SetInput(myPassFilter.at(anId)->GetOutput());
+#endif
anId++;
+#if defined __GNUC_2__
+ myPassFilter[anId+1]->SetInput(myPassFilter[anId]->GetOutput());
+#else
myPassFilter.at(anId+1)->SetInput(myPassFilter.at(anId)->GetOutput());
+#endif
anId++;
+#if defined __GNUC_2__
+ myTransformFilter->SetInput(myPassFilter[anId]->GetPolyDataOutput());
+#else
myTransformFilter->SetInput(myPassFilter.at(anId)->GetPolyDataOutput());
+#endif
anId++;
+#if defined __GNUC_2__
+ myPassFilter[anId]->SetInput(myTransformFilter->GetOutput());
+ myPassFilter[anId+1]->SetInput(myPassFilter[anId]->GetOutput());
+#else
myPassFilter.at(anId)->SetInput(myTransformFilter->GetOutput());
myPassFilter.at(anId+1)->SetInput(myPassFilter.at(anId)->GetOutput());
+#endif
anId++;
if(vtkDataSetMapper* aMapper = dynamic_cast<vtkDataSetMapper*>(theMapper))
+#if defined __GNUC_2__
+ aMapper->SetInput(myPassFilter[anId]->GetOutput());
+#else
aMapper->SetInput(myPassFilter.at(anId)->GetOutput());
+#endif
else if(vtkPolyDataMapper* aMapper = dynamic_cast<vtkPolyDataMapper*>(theMapper))
+#if defined __GNUC_2__
+ aMapper->SetInput(myPassFilter[anId]->GetPolyDataOutput());
+#else
aMapper->SetInput(myPassFilter.at(anId)->GetPolyDataOutput());
+#endif
}
vtkLODActor::SetMapper(theMapper);
}
static int MYDEBUG = 0;
#endif
+#if defined __GNUC__
+ #if __GNUC__ == 2
+ #define __GNUC_2__
+ #endif
+#endif
+
vtkStandardNewMacro(SALOME_ExtractUnstructuredGrid);
vtkIdType SALOME_ExtractUnstructuredGrid::GetOutId(int theOutId) const{
if(myCellIds.empty() && myCellTypes.empty()) return theOutId;
if(myOut2InId.empty() || theOutId > myOut2InId.size()) return -1;
+#if defined __GNUC_2__
+ return myOut2InId[theOutId];
+#else
return myOut2InId.at(theOutId);
+#endif
}
vtkIdType SALOME_ExtractUnstructuredGrid::GetInId(int theInId) const{
static int MYDEBUGWITHFILES = 0;
#endif
+#if defined __GNUC__
+ #if __GNUC__ == 2
+ #define __GNUC_2__
+ #endif
+#endif
+
vtkCxxRevisionMacro(SALOME_GeometryFilter, "$Revision$");
vtkStandardNewMacro(SALOME_GeometryFilter);
vtkIdType SALOME_GeometryFilter::GetObjId(int theVtkID){
if(myVTK2ObjIds.empty() || theVtkID > myVTK2ObjIds.size()) return -1;
+#if defined __GNUC_2__
+ return myVTK2ObjIds[theVtkID];
+#else
return myVTK2ObjIds.at(theVtkID);
+#endif
}
SALOME_GeometryFilter::TVectorId SALOME_GeometryFilter::GetVtkId(int theObjID){
TVectorId aVect;
if(myObj2VTKIds.empty() || theObjID > myObj2VTKIds.size()) return aVect;
+#if defined __GNUC_2__
+ return myObj2VTKIds[theObjID];
+#else
return myObj2VTKIds.at(theObjID);
+#endif
}