cesium-native 0.44.2
Loading...
Searching...
No Matches
SubtreeWriter.h
1#pragma once
2
3#include <Cesium3DTilesWriter/Library.h>
4#include <CesiumJsonWriter/ExtensionWriterContext.h>
5
6// forward declarations
7namespace Cesium3DTiles {
8struct Subtree;
9}
10
11namespace Cesium3DTilesWriter {
12
17struct CESIUM3DTILESWRITER_API SubtreeWriterResult {
21 std::vector<std::byte> subtreeBytes;
22
26 std::vector<std::string> errors;
27
31 std::vector<std::string> warnings;
32};
33
37struct CESIUM3DTILESWRITER_API SubtreeWriterOptions {
41 bool prettyPrint = false;
42};
43
79
80} // namespace Cesium3DTilesWriter
SubtreeWriterResult writeSubtree(const Cesium3DTiles::Subtree &subtree, const SubtreeWriterOptions &options=SubtreeWriterOptions()) const
Serializes the provided subtree object into a byte vector using the provided flags to convert.
CesiumJsonWriter::ExtensionWriterContext & getExtensions()
Gets the context used to control how subtree extensions are written.
SubtreeWriter()
Constructs a new instance.
const CesiumJsonWriter::ExtensionWriterContext & getExtensions() const
Gets the context used to control how subtree extensions are written.
A context for writing extensions where known extensions and their handlers can be registered.
Classes for writing 3D Tiles.
Definition Library.h:8
Classes for using 3D Tiles.
Definition Buffer.h:7
Options for how to write a subtree.
The result of writing a subtree with SubtreeWriter::writeSubtree.
std::vector< std::byte > subtreeBytes
The final generated std::vector<std::byte> of the subtree JSON.
std::vector< std::string > warnings
Warnings, if any, that occurred during the write process.
std::vector< std::string > errors
Errors, if any, that occurred during the write process.
An object describing the availability of tiles and content in a subtree, as well as availability of c...
Definition Subtree.h:24