00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkXMLPImageDataReader.h,v $ 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00039 #ifndef __vtkXMLPImageDataReader_h 00040 #define __vtkXMLPImageDataReader_h 00041 00042 #include "vtkXMLPStructuredDataReader.h" 00043 00044 class vtkImageData; 00045 00046 class VTK_IO_EXPORT vtkXMLPImageDataReader : public vtkXMLPStructuredDataReader 00047 { 00048 public: 00049 vtkTypeRevisionMacro(vtkXMLPImageDataReader,vtkXMLPStructuredDataReader); 00050 void PrintSelf(ostream& os, vtkIndent indent); 00051 static vtkXMLPImageDataReader *New(); 00052 00054 00055 void SetOutput(vtkImageData *output); 00056 vtkImageData *GetOutput(); 00057 vtkImageData *GetOutput(int idx); 00059 00060 protected: 00061 vtkXMLPImageDataReader(); 00062 ~vtkXMLPImageDataReader(); 00063 00064 double Origin[3]; 00065 double Spacing[3]; 00066 00067 vtkImageData* GetPieceInput(int index); 00068 00069 const char* GetDataSetName(); 00070 void SetOutputExtent(int* extent); 00071 void GetPieceInputExtent(int index, int* extent); 00072 int ReadPrimaryElement(vtkXMLDataElement* ePrimary); 00073 void SetupOutputInformation(); 00074 vtkXMLDataReader* CreatePieceReader(); 00075 00076 private: 00077 vtkXMLPImageDataReader(const vtkXMLPImageDataReader&); // Not implemented. 00078 void operator=(const vtkXMLPImageDataReader&); // Not implemented. 00079 }; 00080 00081 #endif