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

dox/IO/vtkBMPReader.h

Go to the documentation of this file.
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkBMPReader.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 =========================================================================*/ 00050 #ifndef __vtkBMPReader_h 00051 #define __vtkBMPReader_h 00052 00053 #include "vtkImageReader.h" 00054 class vtkLookupTable; 00055 00056 class VTK_IO_EXPORT vtkBMPReader : public vtkImageReader 00057 { 00058 public: 00059 static vtkBMPReader *New(); 00060 vtkTypeRevisionMacro(vtkBMPReader,vtkImageReader); 00061 00062 void PrintSelf(ostream& os, vtkIndent indent); 00063 00065 00066 vtkGetMacro(Depth,int); 00068 00070 virtual int CanReadFile(const char* fname); 00071 // Description: 00072 // Get the file extensions for this format. 00073 // Returns a string with a space separated list of extensions in 00074 // the format .extension 00075 virtual const char* GetFileExensions() 00076 { 00077 return ".bmp"; 00078 } 00080 00082 00084 virtual const char* GetDescriptiveName() 00085 { 00086 return "Windows BMP"; 00087 } 00089 00091 00094 vtkSetMacro(Allow8BitBMP,int); 00095 vtkGetMacro(Allow8BitBMP,int); 00096 vtkBooleanMacro(Allow8BitBMP,int); 00098 00099 vtkLookupTable *GetLookupTable(void); 00100 00101 //BTX 00103 00104 vtkGetMacro(Colors,unsigned char *); 00106 //ETX 00107 00108 protected: 00109 vtkBMPReader(); 00110 ~vtkBMPReader(); 00111 00112 unsigned char *Colors; 00113 short Depth; 00114 int Allow8BitBMP; 00115 vtkLookupTable *LookupTable; 00116 00117 virtual void ComputeDataIncrements(); 00118 virtual void ExecuteInformation(); 00119 virtual void ExecuteData(vtkDataObject *out); 00120 private: 00121 vtkBMPReader(const vtkBMPReader&); // Not implemented. 00122 void operator=(const vtkBMPReader&); // Not implemented. 00123 }; 00124 #endif 00125 00126