[MOAB-dev] r4553 - MOAB/trunk/tools/vtkMOABReader

tautges at mcs.anl.gov tautges at mcs.anl.gov
Tue Mar 8 23:47:37 CST 2011


Author: tautges
Date: 2011-03-08 23:47:36 -0600 (Tue, 08 Mar 2011)
New Revision: 4553

Modified:
   MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx
Log:
Various fixes to vtk reader, mostly fixing the too-many-multiblock datasets-created problem.



Modified: MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx
===================================================================
--- MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx	2011-03-08 20:49:05 UTC (rev 4552)
+++ MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx	2011-03-09 05:47:36 UTC (rev 4553)
@@ -106,12 +106,9 @@
   vtkMultiBlockDataSet *get_mbdataset(vtkMultiBlockDataSet *output,
                                       EntityHandle eset, bool create_if_missing = false);
   
-  vtkExtractCells *get_ecdataset(vtkMultiBlockDataSet *output,
-                                 EntityHandle eset, bool create_if_missing = false);
-  
   ErrorCode get_category_name(EntityHandle eset, std::string &cat_name);
 
-  ErrorCode recursive_process_set(EntityHandle eset, vtkMultiBlockDataSet *output);
+  ErrorCode recursive_process_set(vtkMultiBlockDataSet *output, EntityHandle eset);
 
   ErrorCode process_parent_sets(vtkMultiBlockDataSet *output);
 
@@ -338,11 +335,11 @@
     iConstructedMOAB = true;
   }
 
-  mbImpl->query_interface("WriteUtilIface", reinterpret_cast<void**>(&iFace));
-  assert(NULL != iFace);
+  ErrorCode rval = mbImpl->query_interface(iFace);
+  assert(MB_SUCCESS == rval);
 
   vtkIdType def_val = -1;
-  ErrorCode rval = mbImpl->tag_create("__vtkCellTag", sizeof(vtkIdType), MB_TAG_DENSE, MB_TYPE_INTEGER, 
+  rval = mbImpl->tag_create("__vtkCellTag", sizeof(vtkIdType), MB_TAG_DENSE, MB_TYPE_INTEGER, 
                                       vtkCellTag, &def_val, true);
   assert(MB_SUCCESS == rval || MB_ALREADY_ALLOCATED == rval);
 
@@ -390,7 +387,7 @@
 {
   if (mbImpl && iConstructedMOAB) {
     if (iFace)
-      mbImpl->release_interface("WriteUtilIface", reinterpret_cast<void*>(iFace));
+      mbImpl->release_interface(iFace);
 
     delete mbImpl;
   }
@@ -985,7 +982,7 @@
   output->GetMetaData(blockI)->Set(vtkCompositeDataSet::NAME(), "Parent Sets");
 
   for (Range::iterator rit = par_sets.begin(); rit != par_sets.end(); rit++) {
-    rval = recursive_process_set(*rit, ds);
+    rval = recursive_process_set(ds, *rit);
     if (MB_SUCCESS != rval) return rval;
   }
 


More information about the moab-dev mailing list