Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

IO/vtkPNGWriter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkPNGWriter.h,v $
00005   Language:  C++
00006 
00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen 
00008   All rights reserved.
00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00010 
00011      This software is distributed WITHOUT ANY WARRANTY; without even 
00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00013      PURPOSE.  See the above copyright notice for more information.
00014 
00015 =========================================================================*/
00047 #ifndef __vtkPNGWriter_h
00048 #define __vtkPNGWriter_h
00049 
00050 #include "vtkImageWriter.h"
00051 
00052 class vtkImageData;
00053 class vtkUnsignedCharArray;
00054 
00055 class VTK_IO_EXPORT vtkPNGWriter : public vtkImageWriter
00056 {
00057 public:
00058   static vtkPNGWriter *New();
00059   vtkTypeRevisionMacro(vtkPNGWriter,vtkImageWriter);
00060   void PrintSelf(ostream& os, vtkIndent indent);
00061 
00063   virtual void Write();
00064 
00066 
00067   vtkSetMacro(WriteToMemory, unsigned int);
00068   vtkGetMacro(WriteToMemory, unsigned int);
00069   vtkBooleanMacro(WriteToMemory, unsigned int);
00071   
00073 
00075   virtual void SetResult(vtkUnsignedCharArray*);
00076   vtkGetObjectMacro(Result, vtkUnsignedCharArray);
00078 
00079 protected:
00080   vtkPNGWriter();
00081   ~vtkPNGWriter();
00082   
00083   void WriteSlice(vtkImageData *data);
00084   unsigned int WriteToMemory;
00085   vtkUnsignedCharArray *Result;
00086 
00087 private:
00088   vtkPNGWriter(const vtkPNGWriter&);  // Not implemented.
00089   void operator=(const vtkPNGWriter&);  // Not implemented.
00090 };
00091 
00092 #endif
00093 
00094