Viskores
1.0
viskores
io
ImageWriterPNM.h
Go to the documentation of this file.
1
//============================================================================
2
// The contents of this file are covered by the Viskores license. See
3
// LICENSE.txt for details.
4
//
5
// By contributing to this file, all contributors agree to the Developer
6
// Certificate of Origin Version 1.1 (DCO 1.1) as stated in DCO.txt.
7
//============================================================================
8
9
//============================================================================
10
// Copyright (c) Kitware, Inc.
11
// All rights reserved.
12
// See LICENSE.txt for details.
13
//
14
// This software is distributed WITHOUT ANY WARRANTY; without even
15
// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
16
// PURPOSE. See the above copyright notice for more information.
17
//============================================================================
18
#ifndef viskores_io_ImageWriterPNM_h
19
#define viskores_io_ImageWriterPNM_h
20
21
#include <
viskores/io/ImageWriterBase.h
>
22
23
namespace
viskores
24
{
25
namespace
io
26
{
27
38
class
VISKORES_IO_EXPORT
ImageWriterPNM
:
public
viskores::io::ImageWriterBase
39
{
40
using
Superclass
=
viskores::io::ImageWriterBase
;
41
42
public
:
43
using
Superclass::Superclass;
44
VISKORES_CONT
~
ImageWriterPNM
() noexcept override;
45
ImageWriterPNM
(const
ImageWriterPNM
&) = delete;
46
ImageWriterPNM
& operator=(const
ImageWriterPNM
&) = delete;
47
53
VISKORES_CONT
void
Write(
viskores
::
Id
width,
54
viskores
::
Id
height,
55
const
ColorArrayType
& pixels) override;
56
57
protected:
58
template <typename PixelType>
59
VISKORES_CONT
void
WriteToFile(
viskores
::
Id
width,
60
viskores
::
Id
height,
61
const
ColorArrayType
& pixels);
62
};
63
}
64
}
// namespace viskores::io
65
66
#endif //viskores_io_ImageWriterPNM_h
viskores::cont::ArrayHandle
Manages an array-worth of data.
Definition:
ArrayHandle.h:313
viskores::io::ImageWriterBase
Manages writing, and loading data from images.
Definition:
ImageWriterBase.h:43
viskores::Id
viskores::Int64 Id
Base type to use to index arrays.
Definition:
Types.h:235
VISKORES_CONT
#define VISKORES_CONT
Definition:
ExportMacros.h:65
viskores
Groups connected points that have the same field value.
Definition:
Atomic.h:27
ImageWriterBase.h
viskores::io::ImageWriterPNM
Writes images using the PNM format.
Definition:
ImageWriterPNM.h:38
Generated by
1.8.17