Salome HOME
Copy GAUSS_DATA key
authorYour Name <you@example.com>
Tue, 25 Oct 2022 08:51:05 +0000 (16:51 +0800)
committerAnthony GEAY <anthony.geay@edf.fr>
Tue, 25 Oct 2022 09:08:35 +0000 (11:08 +0200)
src/Plugins/MEDReader/plugin/MEDReaderIO/vtkFileSeriesGroupReader.cxx

index dbea2e4f7d82657c5e4962fe248266f906998aec..31d4702aac9d9671d884dc7b5b20006de9815f93 100644 (file)
@@ -148,6 +148,13 @@ int vtkFileSeriesGroupReader::RequestData(vtkInformation* vtkNotUsed(request),
     this->Reader->UpdateTimeStep(time);
     vtkDataObject* outputReader = vtkMultiBlockDataSet::SafeDownCast(this->Reader->GetOutputDataObject(0))->GetBlock(0);
     output->SetBlock(iProc, outputReader);
+
+    // Copy the GAUSS_DATA info key
+    vtkInformation* mInfo = this->Reader->GetOutputInformation(0);
+    if (mInfo->Has(vtkMEDReader::GAUSS_DATA()))
+    {
+      info->CopyEntry(mInfo, vtkMEDReader::GAUSS_DATA());
+    }
   }
   else
   {
@@ -183,6 +190,13 @@ int vtkFileSeriesGroupReader::RequestData(vtkInformation* vtkNotUsed(request),
         output->SetBlock(i + offFile, outputLeaf);
       }
     }
+
+    // Copy the GAUSS_DATA info key for the last reader
+    vtkInformation* mInfo = this->Reader->GetOutputInformation(0);
+    if (mInfo->Has(vtkMEDReader::GAUSS_DATA()))
+    {
+      info->CopyEntry(mInfo, vtkMEDReader::GAUSS_DATA());
+    }
   }
   return 1;
 }