VTK  9.4.20241117
vtkJSONImageWriter.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
14#ifndef vtkJSONImageWriter_h
15#define vtkJSONImageWriter_h
16
17#include "vtkIOImageModule.h" // For export macro
18#include "vtkImageAlgorithm.h"
19
20VTK_ABI_NAMESPACE_BEGIN
21class VTKIOIMAGE_EXPORT vtkJSONImageWriter : public vtkImageAlgorithm
22{
23public:
26 void PrintSelf(ostream& os, vtkIndent indent) override;
27
29
35
37
40 vtkSetStringMacro(ArrayName);
41 vtkGetStringMacro(ArrayName);
43
45
48 vtkSetMacro(Slice, int);
49 vtkGetMacro(Slice, int);
51
55 virtual void Write();
56
57protected:
60
61 char* FileName;
62 char* ArrayName;
63 int Slice;
64
65 int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
66 vtkInformationVector* outputVector) override;
67
68private:
70 void operator=(const vtkJSONImageWriter&) = delete;
71};
72
73VTK_ABI_NAMESPACE_END
74#endif
Generic algorithm superclass for image algs.
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Writes vtkImageData to a JSON file.
static vtkJSONImageWriter * New()
~vtkJSONImageWriter() override
int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called in response to a REQUEST_DATA request from the executive.
vtkGetFilePathMacro(FileName)
Specify file name for the image file.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkSetFilePathMacro(FileName)
Specify file name for the image file.
virtual void Write()
The main interface which triggers the writer to start.