VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkFacetWriter.h 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 =========================================================================*/ 00038 #ifndef __vtkFacetWriter_h 00039 #define __vtkFacetWriter_h 00040 00041 #include "vtkIOGeometryModule.h" // For export macro 00042 #include "vtkPolyDataAlgorithm.h" 00043 00044 class vtkInformation; 00045 00046 class VTKIOGEOMETRY_EXPORT vtkFacetWriter : public vtkPolyDataAlgorithm 00047 { 00048 public: 00049 static vtkFacetWriter *New(); 00050 vtkTypeMacro(vtkFacetWriter,vtkPolyDataAlgorithm); 00051 void PrintSelf(ostream& os, vtkIndent indent); 00052 00054 00055 vtkSetStringMacro(FileName); 00056 vtkGetStringMacro(FileName); 00058 00060 void Write(); 00061 00062 // BTX 00063 void WriteToStream(ostream* ost); 00064 // ETX 00065 00066 protected: 00067 vtkFacetWriter(); 00068 ~vtkFacetWriter(); 00069 00070 // This is called by the superclass. 00071 // This is the method you should override. 00072 virtual int RequestData(vtkInformation *request, 00073 vtkInformationVector** inputVector, 00074 vtkInformationVector* outputVector); 00075 00076 virtual int FillInputPortInformation(int, vtkInformation *); 00077 00078 // BTX 00079 int WriteDataToStream(ostream* ost, vtkPolyData* data); 00080 // ETX 00081 00082 char *FileName; 00083 ostream *OutputStream; 00084 00085 private: 00086 vtkFacetWriter(const vtkFacetWriter&); // Not implemented. 00087 void operator=(const vtkFacetWriter&); // Not implemented. 00088 }; 00089 00090 #endif 00091