define mesh-type in Processing base class
parent
e843b6dcd3
commit
c3407c7730
|
@ -26,7 +26,6 @@ ProcessFields::ProcessFields(Operator* op, Engine* eng) : Processing(op, eng)
|
|||
m_DumpType = E_FIELD_DUMP;
|
||||
// vtk-file is default
|
||||
m_fileType = VTK_FILETYPE;
|
||||
m_Mesh_Type = CARTESIAN_MESH;
|
||||
SetSubSampling(1);
|
||||
SetPrecision(6);
|
||||
|
||||
|
|
|
@ -30,7 +30,6 @@ public:
|
|||
enum FileType { VTK_FILETYPE, HDF5_FILETYPE};
|
||||
enum DumpType { E_FIELD_DUMP, H_FIELD_DUMP};
|
||||
enum DumpMode { NO_INTERPOLATION, NODE_INTERPOLATE, CELL_INTERPOLATE};
|
||||
enum MeshType { CARTESIAN_MESH, CYLINDRICAL_MESH};
|
||||
|
||||
virtual void InitProcess();
|
||||
|
||||
|
@ -76,7 +75,6 @@ public:
|
|||
double CalcTotalEnergy() const;
|
||||
|
||||
void SetFileType(FileType fileType) {m_fileType=fileType;}
|
||||
void SetMeshType(MeshType meshType) {m_Mesh_Type=meshType;}
|
||||
|
||||
static string GetFieldNameByType(DumpType type);
|
||||
static string GetInterpolationNameByType(DumpMode mode);
|
||||
|
@ -85,7 +83,6 @@ public:
|
|||
protected:
|
||||
DumpMode m_DumpMode;
|
||||
DumpType m_DumpType;
|
||||
MeshType m_Mesh_Type;
|
||||
string filePattern;
|
||||
FileType m_fileType;
|
||||
|
||||
|
|
|
@ -35,6 +35,7 @@ Processing::Processing(Operator* op, Engine* eng)
|
|||
m_weight=1;
|
||||
m_Flush = false;
|
||||
m_dualMesh = false;
|
||||
m_Mesh_Type = CARTESIAN_MESH;
|
||||
}
|
||||
|
||||
Processing::~Processing()
|
||||
|
|
|
@ -30,6 +30,8 @@ public:
|
|||
Processing(Operator* op, Engine* eng);
|
||||
virtual ~Processing();
|
||||
|
||||
enum MeshType { CARTESIAN_MESH, CYLINDRICAL_MESH};
|
||||
|
||||
virtual void SetName(string val) {m_Name=val;}
|
||||
|
||||
virtual void InitProcess() {};
|
||||
|
@ -60,6 +62,8 @@ public:
|
|||
virtual void FlushNext() {m_Flush = true;}
|
||||
virtual void FlushData() {};
|
||||
|
||||
void SetMeshType(MeshType meshType) {m_Mesh_Type=meshType;}
|
||||
|
||||
//! Set the dump precision
|
||||
void SetPrecision(unsigned int val) {m_precision = val;}
|
||||
|
||||
|
@ -72,6 +76,8 @@ public:
|
|||
protected:
|
||||
Operator* Op;
|
||||
Engine* Eng;
|
||||
MeshType m_Mesh_Type;
|
||||
|
||||
unsigned int m_precision;
|
||||
|
||||
string m_Name;
|
||||
|
|
|
@ -393,6 +393,8 @@ int openEMS::SetupFDTD(const char* file)
|
|||
cerr << "openEMS::SetupFDTD: Warning: Probe type " << pb->GetProbeType() << " of property '" << pb->GetName() << "' is unknown..." << endl;
|
||||
continue;
|
||||
}
|
||||
if (CylinderCoords)
|
||||
proc->SetMeshType(Processing::CYLINDRICAL_MESH);
|
||||
proc->SetProcessInterval(Nyquist/m_OverSampling);
|
||||
proc->AddFrequency(pb->GetFDSamples());
|
||||
proc->SetName(pb->GetName());
|
||||
|
@ -432,7 +434,7 @@ int openEMS::SetupFDTD(const char* file)
|
|||
ProcTD->SetDumpMode((ProcessFields::DumpMode)db->GetDumpMode());
|
||||
ProcTD->SetFileType((ProcessFields::FileType)db->GetFileType());
|
||||
if (CylinderCoords)
|
||||
ProcTD->SetMeshType(ProcessFields::CYLINDRICAL_MESH);
|
||||
ProcTD->SetMeshType(Processing::CYLINDRICAL_MESH);
|
||||
for (int n=0;n<3;++n)
|
||||
ProcTD->SetSubSampling(db->GetSubSampling(n),n);
|
||||
ProcTD->SetFilePattern(db->GetName());
|
||||
|
|
Loading…
Reference in New Issue