ludus::geometry::content¶
Ludus Wiki · API overview · Browse API
Namespace
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
Related declarations¶
- ludus::geometry::content::Cancellation
- ludus::geometry::content::AuthoredSpan
- ludus::geometry::content::AuthoredWaypoint
- ludus::geometry::content::AuthoredKey
- ludus::geometry::content::AuthoredPatch
- ludus::geometry::content::GeometrySource
- ludus::geometry::content::GeometryDiagnosticReport
- ludus::geometry::content::GeometryCacheKey
- ludus::geometry::content::GeometryLoad
Enumerations¶
GeometrySourceMode¶
enum class GeometrySourceMode : uint8
Related types: uint8
CubicPath¶
CubicPath
HermitePath¶
HermitePath
CatmullRomPath¶
CatmullRomPath
ScalarTrack¶
ScalarTrack
PatchSurface¶
PatchSurface
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
HandleMode¶
enum class HandleMode : uint8
Related types: uint8
Automatic¶
Automatic
Manual¶
Manual
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
Constants and variables¶
SOURCE_SCHEMA_VERSION¶
constexpr uint64 ludus::geometry::content::SOURCE_SCHEMA_VERSION = 1
Related types: uint64
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
CATALOG_KIND¶
constexpr std::string_view ludus::geometry::content::CATALOG_KIND = "cooked-geometry"
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
Functions¶
ParseGeometrySource¶
ludus::content::Status ludus::geometry::content::ParseGeometrySource(std::string_view json, GeometrySource &outSource, GeometryDiagnosticReport &outDiagnostic) noexcept
| Parameter | Description |
|---|---|
json |
Source text, at most MAX_SOURCE_BYTES.
|
outSource |
Replaced only on success.
|
outDiagnostic |
Set on every failure; cleared to Ok on success.
|
Returns
Related types: GeometrySource · ludus::content::Status · GeometryDiagnosticReport
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
WriteGeometrySource¶
ludus::content::Status ludus::geometry::content::WriteGeometrySource(const GeometrySource &source, ludus::content::Bytes &outJson, GeometryDiagnosticReport &outDiagnostic) noexcept
| Parameter | Description |
|---|---|
source |
Validated source.
|
outJson |
Replaced on success.
|
outDiagnostic |
Set on failure.
|
Returns
Related types: ludus::content::Bytes · GeometrySource · ludus::content::Status · GeometryDiagnosticReport
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
CookGeometry¶
ludus::content::Status ludus::geometry::content::CookGeometry(const GeometrySource &source, core::Array< uint8 > &outBlob, GeometryDiagnosticReport &outDiagnostic, const Cancellation *cancelOrNull=nullptr) noexcept
| Parameter | Description |
|---|---|
source |
Validated source.
|
outBlob |
Replaced only on success; preserved on failure or cancellation.
|
outDiagnostic |
Set on failure.
|
cancelOrNull |
Optional cancellation hook; nullptr disables it.
|
Returns
Related types: core::Array · GeometrySource · ludus::content::Status · uint8 · Cancellation · GeometryDiagnosticReport
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h
LoadGeometry¶
ludus::content::Status ludus::geometry::content::LoadGeometry(std::span< const uint8 > blob, const geom::WorkLimits &limits, GeometryLoad &outLoad, GeometryDiagnosticReport &outDiagnostic) noexcept
| Parameter | Description |
|---|---|
blob |
Cooked bytes, borrowed for the call only.
|
limits |
Preparation work limits (peak memory, leaves, depth, ...).
|
outLoad |
Replaced only on success; unchanged on every failure.
|
outDiagnostic |
Set on failure.
|
Returns
Related types: GeometryLoad · ludus::content::Status · uint8 · GeometryDiagnosticReport
Declared in modules/geometry/content/include/ludus/geometry/content/geometry_content.h