MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ resolve_mesh()

std::optional< Kakshya::MeshData > MayaFlux::Buffers::DataReadProcessor::resolve_mesh ( )

Finish a read_mesh() read as MeshData.

Returns nullopt, leaving the result pending, when the pending read was not a mesh read.

Definition at line 354 of file DataReadProcessor.cpp.

355{
356 auto pending = collect_result(ReadKind::Mesh);
357 if (!pending) {
358 return std::nullopt;
359 }
360
361 if (pending->mesh) {
362 return std::move(pending->mesh);
363 }
364
365 return triangle_soup_mesh(pending->bytes);
366}
std::unique_ptr< PendingRead > collect_result(ReadKind kind)
std::optional< Kakshya::MeshData > triangle_soup_mesh(std::span< const uint8_t > vertex_bytes)
Wrap non-indexed triangle vertices as MeshData.

References collect_result(), Mesh, and MayaFlux::Buffers::triangle_soup_mesh().

Referenced by MayaFlux::Kriya::detail::resolve_graphics_read().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: