载入中...
搜索中...
未找到
Gpgpu.h
浏览该文件的文档.
Definition Module.h:43
Backend-agnostic compute program. Bind storage buffers then dispatch via Gpgpu::dispatch....
Definition ComputeShader.h:15
GPGPU module — compute shaders + storage buffers via the active Graphics backend. Uses the graphics q...
Definition Gpgpu.h:20
Module_REG(Gpgpu)
ComputeShader * newShaderFromSpvFile(const std::string &path)
Vulkan SPIR-V compatibility wrapper → newShaderFromBytecode.
Definition Gpgpu.cpp:79
ComputeShader * newShader(const std::string &source)
Compile compute source for the active backend (Vulkan: GLSL via glslc).
Definition Gpgpu.cpp:48
bool isAvailable() const
True when the active Graphics backend can run compute (device initialized).
Definition Gpgpu.cpp:38
ComputeShader * newShaderFromBytecode(const std::string &path)
Load precompiled compute bytecode from Filesystem path (Vulkan: SPIR-V).
Definition Gpgpu.cpp:61
Gpgpu()=default
void dispatch(ComputeShader *shader, int groupsX, int groupsY=1, int groupsZ=1)
Record + submit a compute dispatch and wait for completion (sync). groups*: workgroup counts (not thr...
Definition Gpgpu.cpp:116
GpuBuffer * newBuffer(int byteSize, const std::string &usage="storage")
Allocate a GPU buffer. usage: "storage" (SSBO, device-local) | "staging" (host-visible transfer).
Definition Gpgpu.cpp:92
Sequence * newSequence()
Create a Kompute-style command Sequence: record buffer transfers and compute dispatches into one comm...
Definition Gpgpu.cpp:104
~Gpgpu() override=default
Backend-agnostic GPU buffer for compute (storage) or CPU staging transfers. Squirrel-owned; derived c...
Definition GpuBuffer.h:16
Definition Sequence.h:32
Definition ComputeShader.cpp:3