simvx.graphics.gpu.context

GPU context: bundles core Vulkan handles used throughout the renderer.

Module Contents

Classes

GPUContext

Immutable bag of GPU handles shared across all renderer passes.

Data

API

simvx.graphics.gpu.context.__all__

[‘GPUContext’]

class simvx.graphics.gpu.context.GPUContext(device: Any, physical_device: Any, graphics_queue: Any, present_queue: Any, graphics_qf: int, cmd_ctx: simvx.graphics.gpu.commands.CommandContext, compute_queue: Any = None, transfer_queue: Any = None, compute_qf: int | None = None, transfer_qf: int | None = None, multi_gpu: bool = False, device_count: int = 1)[source]

Immutable bag of GPU handles shared across all renderer passes.

Created once during Vulkan init and stored on Engine as engine.ctx. Renderer passes should accept or store this rather than reaching into engine internals.

Initialization

__slots__

(‘device’, ‘physical_device’, ‘graphics_queue’, ‘present_queue’, ‘graphics_qf’, ‘cmd_ctx’, ‘compute_…

property command_pool: Any[source]

Shorthand for cmd_ctx.pool.

property async_compute: bool[source]

True when a dedicated compute queue exists (multi-queue GPU).

The single capability gate every consumer reads: True selects the async-compute scheduler path (compute passes -> compute queue, graphics submit waits on a semaphore); False is the byte-identical single-queue fallback verified on this box.

property concurrent_compute_families: list[int] | None[source]

Distinct [graphics_qf, compute_qf] for CONCURRENT buffers, or None when async-compute is off.

Pass this to :func:~simvx.graphics.gpu.memory.create_buffer’s concurrent_families for any control buffer (indirect / visibility / light-grid / particle) that crosses the graphics<->compute boundary. None keeps those buffers EXCLUSIVE (unchanged single-queue path).