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

tautges at mcs.anl.gov tautges at mcs.anl.gov
Sat Dec 18 22:57:26 CST 2010


Author: tautges
Date: 2010-12-18 22:57:26 -0600 (Sat, 18 Dec 2010)
New Revision: 4386

Added:
   MOAB/trunk/tools/vtkMOABReader/CMakeLists.txt
   MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.xml
   MOAB/trunk/tools/vtkMOABReader/vtkMOABReaderGUI.xml
Modified:
   MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx
   MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.h
Log:
A working paraview-MOAB reader.  Requires local compile of Paraview for the
time being.



Added: MOAB/trunk/tools/vtkMOABReader/CMakeLists.txt
===================================================================
--- MOAB/trunk/tools/vtkMOABReader/CMakeLists.txt	                        (rev 0)
+++ MOAB/trunk/tools/vtkMOABReader/CMakeLists.txt	2010-12-19 04:57:26 UTC (rev 4386)
@@ -0,0 +1,13 @@
+SET(MOAB_DIR "." CACHE PATH "MOAB base directory")
+if (MOAB_DIR)
+  INCLUDE_DIRECTORIES(${MOAB_DIR}/include)
+  LINK_DIRECTORIES(${MOAB_DIR}/lib)
+  LINK_LIBRARIES(MOAB)
+CMAKE_MINIMUM_REQUIRED(VERSION 2.6.3)
+FIND_PACKAGE(ParaView REQUIRED)
+INCLUDE(${PARAVIEW_USE_FILE})
+ ADD_PARAVIEW_PLUGIN(vtkMOABReader "4.0" 
+   SERVER_MANAGER_XML vtkMOABReader.xml
+   SERVER_MANAGER_SOURCES vtkMOABReader.cxx 
+   GUI_RESOURCE_FILES vtkMOABReaderGUI.xml)
+endif (MOAB_DIR)

Modified: MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx
===================================================================
--- MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx	2010-12-18 14:43:12 UTC (rev 4385)
+++ MOAB/trunk/tools/vtkMOABReader/vtkMOABReader.cxx	2010-12-19 04:57:26 UTC (rev 4386)
@@ -24,7 +24,11 @@
 #include "vtkUnstructuredGrid.h"
 #include "vtkExtractUnstructuredGrid.h"
 #include "vtkThreshold.h"
+#include "vtkDoubleArray.h"
+#include "vtkIntArray.h"
+#include "vtkPointData.h"
 #include <sstream>
+#include <vector>
 #include "assert.h"
 #include "MBTagConventions.hpp"
 
@@ -70,6 +74,7 @@
   
     // make an offset id tag
   moab::ErrorCode result;
+  int success;
   if (0 == VtkOffsetIdTag) {
     
     result = gMB->tag_get_handle("__vtk_offset_id_tag", VtkOffsetIdTag);
@@ -92,7 +97,7 @@
   vtkUnstructuredGrid *ug = this->GetOutput();
   ug->Allocate();
   
-  result = construct_mesh();
+  success = construct_mesh();
   if (MB_SUCCESS != result)
     {


More information about the moab-dev mailing list