VTK  9.1.0
vtkGLTFWriter.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkGLTFWriter.h
5
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13
14=========================================================================*/
32#ifndef vtkGLTFWriter_h
33#define vtkGLTFWriter_h
34
35#include "vtkIOGeometryModule.h" // For export macro
36#include "vtkWriter.h"
37
38#include <string> // for std::string
39
41class VTKIOGEOMETRY_EXPORT vtkGLTFWriter : public vtkWriter
42{
43public:
44 static vtkGLTFWriter* New();
45 vtkTypeMacro(vtkGLTFWriter, vtkWriter);
46 void PrintSelf(ostream& os, vtkIndent indent) override;
47
49
52 vtkSetStringMacro(FileName);
53 vtkGetStringMacro(FileName);
55
57
60 vtkSetStringMacro(TextureBaseDirectory);
61 vtkGetStringMacro(TextureBaseDirectory);
63
65
69 vtkGetMacro(InlineData, bool);
70 vtkSetMacro(InlineData, bool);
71 vtkBooleanMacro(InlineData, bool);
73
75
82 vtkGetMacro(SaveNormal, bool);
83 vtkSetMacro(SaveNormal, bool);
84 vtkBooleanMacro(SaveNormal, bool);
86
88
98 vtkGetMacro(SaveBatchId, bool);
99 vtkSetMacro(SaveBatchId, bool);
100 vtkBooleanMacro(SaveBatchId, bool);
102
104
106 vtkGetMacro(SaveTextures, bool);
107 vtkSetMacro(SaveTextures, bool);
108 vtkBooleanMacro(SaveTextures, bool);
110
114 std::string WriteToString();
115
119 void WriteToStream(ostream& out, vtkMultiBlockDataSet* in);
120
121protected:
123 ~vtkGLTFWriter() override;
124
125 void WriteData() override;
126 int FillInputPortInformation(int port, vtkInformation* info) override;
127
128 char* FileName;
134
135private:
136 vtkGLTFWriter(const vtkGLTFWriter&) = delete;
137 void operator=(const vtkGLTFWriter&) = delete;
138};
139
140#endif
export a scene into GLTF 2.0 format.
Definition: vtkGLTFWriter.h:42
~vtkGLTFWriter() override
std::string WriteToString()
Write the result to a string instead of a file.
void WriteToStream(ostream &out, vtkMultiBlockDataSet *in)
Write the result to a provided ostream.
static vtkGLTFWriter * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
void WriteData() override
char * TextureBaseDirectory
a simple class to control print indentation
Definition: vtkIndent.h:113
Store vtkAlgorithm input/output information.
Composite dataset that organizes datasets into blocks.
abstract class to write data to file(s)
Definition: vtkWriter.h:46