coastline 0.0.4
Loading...
Searching...
No Matches
n64model.h File Reference
#include <array>
#include <cstddef>
#include <cstdint>
#include <expected>
#include <span>
#include <string>
#include <string_view>
#include <vector>
#include <nlohmann/json.hpp>
Include dependency graph for n64model.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  coastline::GltfImage
 A texture of a glTF document, as the RDP samples it. More...
struct  coastline::GltfModel
 A glTF document, the bytes of its one buffer, and its images. More...

Namespaces

namespace  coastline

Functions

std::expected< GltfModel, std::string > coastline::CarModelToGltf (std::span< const std::uint8_t > bytes, std::size_t imageOffset, std::string_view bufferUri)
 Describe the model of a car as glTF.
std::expected< GltfModel, std::string > coastline::TrackToGltf (std::span< const std::uint8_t > bytes, std::string_view bufferUri)
 Describe a track as glTF.
std::expected< GltfModel, std::string > coastline::FrontEndModelToGltf (std::span< const std::uint8_t > bytes, std::string_view bufferUri)
 Describe a model of the front end, such as a logo of the splash screens, as glTF.
std::expected< std::vector< std::uint8_t >, std::string > coastline::ModelFromGltf (const nlohmann::ordered_json &json, std::span< const std::uint8_t > buffer)
 Build the file of a model or a track from its glTF, the inverse of CarModelToGltf(), TrackToGltf(), and FrontEndModelToGltf().