Loading...
Searching...
No Matches
VTKWriter.hh
//=============================================================================
//
// Implements an IOManager writer module for VTK files
//
//=============================================================================
#ifndef __VTKWRITER_HH__
#define __VTKWRITER_HH__
//=== INCLUDES ================================================================
#include <string>
#include <iosfwd>
#include <OpenMesh/Core/System/config.h>
#include <OpenMesh/Core/Utils/SingletonT.hh>
#include <OpenMesh/Core/IO/exporter/BaseExporter.hh>
#include <OpenMesh/Core/IO/writer/BaseWriter.hh>
//== NAMESPACES ===============================================================
namespace OpenMesh {
namespace IO {
//=== IMPLEMENTATION ==========================================================
class OPENMESHDLLEXPORT _VTKWriter_ : public BaseWriter
{
public:
_VTKWriter_();
std::string get_description() const override { return "VTK"; }
std::string get_extensions() const override { return "vtk"; }
bool write(const std::string&, BaseExporter&, Options, std::streamsize _precision = 6) const override;
bool write(std::ostream&, BaseExporter&, Options, std::streamsize _precision = 6) const override;
size_t binary_size(BaseExporter&, Options) const override { return 0; }
};
//== TYPE DEFINITION ==========================================================
extern _VTKWriter_ __VTKWriterinstance;
OPENMESHDLLEXPORT _VTKWriter_& VTKWriter();
//=============================================================================
} // namespace IO
} // namespace OpenMesh
//=============================================================================
#endif
//=============================================================================
OpenMesh
Contains all the mesh ingredients like the polygonal mesh, the triangle mesh, different mesh kernels ...
Definition MeshItems.hh:59
OpenMesh::IO::__VTKWriterinstance
_VTKWriter_ __VTKWriterinstance
Declare the single entity of the OBJ writer.
Definition VTKWriter.cc:18
OpenMesh::IO::BaseExporter
Base class for exporter modules.
Definition BaseExporter.hh:85
OpenMesh::IO::Options
Set options for reader/writer modules.
Definition Options.hh:91
OpenMesh::IO::BaseWriter
Base class for all writer modules.
Definition BaseWriter.hh:84
OpenMesh::IO::_VTKWriter_
Definition VTKWriter.hh:28
OpenMesh::IO::_VTKWriter_::binary_size
size_t binary_size(BaseExporter &, Options) const override
Returns expected size of file if binary format is supported else 0.
Definition VTKWriter.hh:38
OpenMesh::IO::_VTKWriter_::get_description
std::string get_description() const override
Return short description of the supported file format.
Definition VTKWriter.hh:32
OpenMesh::IO::_VTKWriter_::get_extensions
std::string get_extensions() const override
Return file format's extension.
Definition VTKWriter.hh:33