VTK-m
2.2
|
Writes images using the PNG format. More...
#include <ImageWriterPNG.h>
Public Member Functions | |
~ImageWriterPNG () noexcept override | |
ImageWriterPNG (const ImageWriterPNG &)=delete | |
ImageWriterPNG & | operator= (const ImageWriterPNG &)=delete |
Public Member Functions inherited from vtkm::io::ImageWriterBase | |
ImageWriterBase (const char *filename) | |
ImageWriterBase (const std::string &filename) | |
Construct a writer to save data to the given file. More... | |
virtual | ~ImageWriterBase () noexcept |
ImageWriterBase (const ImageWriterBase &)=delete | |
ImageWriterBase & | operator= (const ImageWriterBase &)=delete |
virtual void | WriteDataSet (const vtkm::cont::DataSet &dataSet, const std::string &colorField={}) |
Write the color field of a data set to an image file. More... | |
PixelDepth | GetPixelDepth () const |
Specify the number of bits used by each color channel. More... | |
void | SetPixelDepth (PixelDepth depth) |
Specify the number of bits used by each color channel. More... | |
const std::string & | GetFileName () const |
void | SetFileName (const std::string &filename) |
Protected Member Functions | |
void | Write (vtkm::Id width, vtkm::Id height, const ColorArrayType &pixels) override |
template<typename PixelType > | |
void | WriteToFile (vtkm::Id width, vtkm::Id height, const ColorArrayType &pixels) |
Private Types | |
using | Superclass = vtkm::io::ImageWriterBase |
Additional Inherited Members | |
Public Types inherited from vtkm::io::ImageWriterBase | |
enum | PixelDepth { PixelDepth::PIXEL_8, PixelDepth::PIXEL_16 } |
using | ColorArrayType = vtkm::cont::ArrayHandle< vtkm::Vec4f_32 > |
Protected Attributes inherited from vtkm::io::ImageWriterBase | |
std::string | FileName |
PixelDepth | Depth = PixelDepth::PIXEL_8 |
Writes images using the PNG format.
ImageWriterPNG
is constructed with the name of the file to write. The data is written to the file by calling the WriteDataSet
method.
When writing files, ImageReaderPNG
automatically compresses data to optimal sizes relative to the actual bit complexity of the provided image.
|
private |
|
overridenoexcept |
|
delete |
|
delete |
|
overrideprotectedvirtual |
Implements vtkm::io::ImageWriterBase.
|
protected |