VTK-m  2.0
ImageReaderPNM.h
Go to the documentation of this file.
1 //============================================================================
2 // Copyright (c) Kitware, Inc.
3 // All rights reserved.
4 // See LICENSE.txt for details.
5 //
6 // This software is distributed WITHOUT ANY WARRANTY; without even
7 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8 // PURPOSE. See the above copyright notice for more information.
9 //============================================================================
10 #ifndef vtk_m_io_ImageReaderPNM_h
11 #define vtk_m_io_ImageReaderPNM_h
12 
14 
15 namespace vtkm
16 {
17 namespace io
18 {
19 
28 class VTKM_IO_EXPORT ImageReaderPNM : public ImageReaderBase
29 {
31 
32 public:
33  using Superclass::Superclass;
34  VTKM_CONT ~ImageReaderPNM() noexcept override;
35  ImageReaderPNM(const ImageReaderPNM&) = delete;
36  ImageReaderPNM& operator=(const ImageReaderPNM&) = delete;
37 
38 protected:
39  VTKM_CONT void Read() override;
40 
44  template <typename PixelType>
45  void DecodeFile(std::ifstream& inStream, const vtkm::Id& width, const vtkm::Id& height);
46 };
47 }
48 } // namespace vtkm::io
49 
50 #endif //vtk_m_io_ImageReaderPNM_h
vtkm
Groups connected points that have the same field value.
Definition: Atomic.h:19
vtkm::Id
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
vtkm::io::ImageReaderBase
Manages reading, and loading data from images.
Definition: ImageReaderBase.h:32
VTKM_CONT
#define VTKM_CONT
Definition: ExportMacros.h:57
vtkm::io::ImageReaderPNM
Manages reading images using the PNM format.
Definition: ImageReaderPNM.h:28
ImageReaderBase.h