ludus::graphics::rhi::NativeComputePipelineDescription¶
Ludus Wiki · API overview · Browse API
Struct
Native compute adapter for libraries using a dedicated queue on the same device. RHI owns the queue and orders shared-buffer producers/consumers with native events. Owner-thread callbacks must not reenter RHI, wait for GPU completion or use an unprepared queue. Only Metal storage-buffer bindings are currently admitted. Vulkan/browser reject explicitly.
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
#include <ludus/graphics/rhi/native_compute.h>
struct ludus::graphics::rhi::NativeComputePipelineDescription final
Fields¶
Bindings¶
BindingSetHandle ludus::graphics::rhi::NativeComputePipelineDescription::Bindings {}
Ready, immutable, non-dynamic Compute storage-only snapshot.
Related types: BindingSetHandle
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
ContextOrNull¶
void* ludus::graphics::rhi::NativeComputePipelineDescription::ContextOrNull = nullptr
Caller context; retained on successful creation through GPU retirement.
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
PrepareOrNull¶
RasterStatus(*) ludus::graphics::rhi::NativeComputePipelineDescription::PrepareOrNull(void *, const NativeDeviceIdentity &, foundation::BorrowedView< const NativeComputeBuffer >) noexcept(void *, const NativeDeviceIdentity &, foundation::BorrowedView< const NativeComputeBuffer >) noexcept = nullptr
Prepare/cache native objects between frames. Buffers appear in layout order. The array view expires on return; copied descriptors remain valid through pipeline retirement. Pending retains context and bindings and polls Prepare again without blocking. Private setup may run on a worker; bound buffers must remain untouched until Submit. Drain must join pending private preparation during device shutdown.
Related types: RasterStatus
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
SubmitOrNull¶
RasterStatus(*) ludus::graphics::rhi::NativeComputePipelineDescription::SubmitOrNull(void *) noexcept(void *) noexcept = nullptr
Enqueue GPU work on the exact prepared private queue. RHI orders the prior producer before it, and subsequent consumers/completion after it with native events.
Related types: RasterStatus
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
RetainOrNull¶
void(*) ludus::graphics::rhi::NativeComputePipelineDescription::RetainOrNull(void *) noexcept(void *) noexcept = nullptr
Retain the context without failure or allocation.
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
ReleaseOrNull¶
void(*) ludus::graphics::rhi::NativeComputePipelineDescription::ReleaseOrNull(void *) noexcept(void *) noexcept = nullptr
Release after the last retained GPU use, also on shutdown.
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h
DrainOrNull¶
void(*) ludus::graphics::rhi::NativeComputePipelineDescription::DrainOrNull(void *) noexcept(void *) noexcept = nullptr
Shutdown-only fence for pending private preparation, called before native buffers/queue retire. Must drain even if the caller still retains other context references; must not reenter RHI.
Declared in modules/graphics/rhi/include/ludus/graphics/rhi/native_compute.h