Commit 5c28a4c9 authored by Christophe Geuzaine's avatar Christophe Geuzaine

MEDfileVersionOpen only available since MED 3.2.1

parent c173e544
Pipeline #2602 passed with stage
in 59 minutes and 17 seconds
......@@ -542,7 +542,8 @@ static void writeElementsMED(med_idt &fid, char *meshName,
int GModel::writeMED(const std::string &name, bool saveAll,
double scalingFactor)
{
#if(MED_MAJOR_NUM == 3)
#if(MED_MAJOR_NUM == 3) && (MED_MINOR_NUM >= 3)
// MEDfileVersionOpen actually appeared in MED 3.2.1
med_int major = MED_MAJOR_NUM, minor = MED_MINOR_NUM, release = MED_RELEASE_NUM;
if(CTX::instance()->mesh.medFileMinorVersion >= 0){
minor = (int)CTX::instance()->mesh.medFileMinorVersion;
......
......@@ -905,7 +905,8 @@ bool PViewDataGModel::writeMED(const std::string &fileName)
std::string meshName(model->getName());
std::string fieldName(getName());
#if(MED_MAJOR_NUM == 3)
#if(MED_MAJOR_NUM == 3) && (MED_MINOR_NUM >= 3)
// MEDfileVersionOpen actually appeared in MED 3.2.1
med_int major = MED_MAJOR_NUM, minor = MED_MINOR_NUM, release = MED_RELEASE_NUM;
if(CTX::instance()->mesh.medFileMinorVersion >= 0){
minor = (int)CTX::instance()->mesh.medFileMinorVersion;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment