/**************************************************************************** ** Copyright (c) 2021, Fougue Ltd. ** All rights reserved. ** See license at https://github.com/fougue/mayo/blob/master/LICENSE.txt ****************************************************************************/ #pragma once #include "../base/io_writer.h" #include #include #include namespace Mayo { namespace IO { // Opencascade-based writer for VRML(v2.0 UTF8) file format class OccVrmlWriter : public Writer { public: bool transfer(Span appItems, TaskProgress* progress) override; bool writeFile(const FilePath& filepath, TaskProgress* progress) override; static std::unique_ptr createProperties(PropertyGroup* parentGroup); void applyProperties(const PropertyGroup* params) override; // Parameters struct Parameters { VrmlAPI_RepresentationOfShape shapeRepresentation = VrmlAPI_BothRepresentation; }; Parameters& parameters() { return m_params; } const Parameters& constParameters() const { return m_params; } private: class Properties; Parameters m_params; std::unique_ptr m_scene; VrmlAPI_RepresentationOfShape m_shapeRepresentation = VrmlAPI_BothRepresentation; }; } // namespace IO } // namespace Mayo