载入中...
搜索中...
未找到
eve::gpgpu 命名空间参考

Fluids module — interactive surface fluid simulation. 更多...

类

class  ComputeShader
 Backend-agnostic compute program. Bind storage buffers then dispatch via Gpgpu::dispatch. Push constants: float[32] (same size as graphics::Shader). 更多...
 
class  EcsGpuWorkspace
 Reusable typed CPU staging for a GPU ECS component stream. Ownership stays with the caller; one workspace must not be used concurrently. 更多...
 
class  Gpgpu
 GPGPU module — compute shaders + storage buffers via the active Graphics backend. Uses the graphics queue when no dedicated compute family exists (Apple/MoltenVK). 更多...
 
class  GpuBuffer
 Backend-agnostic GPU buffer for compute (storage) or CPU staging transfers. Squirrel-owned; derived class destroys GPU resources in destructor. 更多...
 
class  Sequence
 EVENGINE_API_WORLD public API. 更多...
 
class  ShaderSystem
 EVENGINE_API_WORLD public API. 更多...
 
class  VulkanComputeShader
 Vulkan 计算着色器(SPIR-V pipeline + descriptor 管理)。 更多...
 
class  VulkanGpuBuffer
 Vulkan 计算缓冲区实现(storage/vertex buffer + device memory)。 更多...
 
struct  VulkanSequence
 VulkanSequence public API. 更多...
 
class  WebGpuComputeShader
 Compute program for the WebGPU backend. Accepts WGSL source; GLSL/SPIR-V input is rejected (browsers only accept WGSL at runtime). 更多...
 
class  WebGpuGpuBuffer
 Storage / staging buffer for the WebGPU backend. 更多...
 
class  WebGpuSequence
 

枚举

enum class  SequenceStatus : uint8_t {
  Idle , Recording , Submitted , Complete ,
  Failed
}
 Observable lifecycle state of a reusable GPU command sequence. 更多...
 

函数

EVENGINE_API_WORLD Result< std::vector< uint32_t > > compileComputeSpirv (const std::string &source)
 Compile GLSL compute source to owning SPIR-V without accessing Graphics or a GPU.
 
EVENGINE_API_WORLD Result< std::unique_ptr< ComputeShader > > createComputeShader (const std::vector< uint32_t > &words)
 Create an owning compute pipeline from valid SPIR-V produced by compileComputeSpirv.
 
template<typename Comp >
constexpr int componentFloatCount ()
 Component float count.
 
template<typename Base , typename Comp >
int countViewEntities ()
 Count live entities matching View<Base, Comp>.
 
template<typename Base , typename Comp >
int packViewComponent (ShaderSystem &sys, int binding, EcsGpuWorkspace< Comp > &workspace)
 Pack View<Base, Comp> into ShaderSystem binding as AoS floats. Returns entity count (0 if empty).
 
template<typename Base , typename Comp >
int packViewComponent (ShaderSystem &sys, int binding)
 Compatibility overload that uses a temporary staging workspace.
 
template<typename Base , typename Comp >
void unpackViewComponent (ShaderSystem &sys, int binding, int count, EcsGpuWorkspace< Comp > &workspace)
 Write ShaderSystem binding floats back into View<Base, Comp> (same order as pack). count should be the value returned by packViewComponent.
 
template<typename Base , typename Comp >
void unpackViewComponent (ShaderSystem &sys, int binding, int count)
 Compatibility overload that uses a temporary staging workspace.
 
template<typename Base , typename Comp >
int packViewComponentRange (ShaderSystem &sys, int binding, int firstEntity, int entityCount, EcsGpuWorkspace< Comp > &workspace)
 Pack a stable contiguous View range into an existing resident buffer. The full buffer must have been allocated by a prior full pack/ensureBuffer.
 
template<typename Base , typename Comp >
int unpackViewComponentRange (ShaderSystem &sys, int binding, int firstEntity, int entityCount, EcsGpuWorkspace< Comp > &workspace)
 Unpack a stable contiguous resident-buffer range into a matching View range.
 
template<typename Base , typename Comp >
int runViewComponentSystem (ShaderSystem &sys, int binding, float dt)
 Pack + dispatch + unpack a single-component GPU system. Additional bindings must be uploaded by the caller before this helper, or use ShaderSystem manually for multi-buffer systems.
 
int packScriptEntityFloats (ssq::Object entities, const std::string &slot, ssq::Object fields, GpuBuffer *buf)
 Pack script ECS entities' component number fields into a GpuBuffer (AoS).
 
int packScriptEntityFloatsRange (ssq::Object entities, const std::string &slot, ssq::Object fields, GpuBuffer *buf, int firstEntity, int entityCount)
 Pack a contiguous entity range into the matching range of an existing buffer.
 
int unpackScriptEntityFloats (ssq::Object entities, const std::string &slot, ssq::Object fields, GpuBuffer *buf, int entityCount)
 Inverse of packScriptEntityFloats: write buffer rows back into component fields.
 
int unpackScriptEntityFloatsRange (ssq::Object entities, const std::string &slot, ssq::Object fields, GpuBuffer *buf, int firstEntity, int entityCount)
 Unpack a contiguous buffer range into the matching stable ECS view range.
 
 Module_IMPL (Gpgpu, new Gpgpu())
 
bool vulkanGpgpuReady ()
 Vulkan 后端是否就绪(设备/队列可用)。
 
ComputeShader * vulkanNewShaderFromSpirv (const std::vector< uint32_t > &spv)
 从 SPIR-V 字节码创建计算着色器。
 
GpuBuffer * vulkanNewBuffer (int byteSize, const std::string &usage)
 创建 GPU 存储/传输缓冲区;usage 为 "storage" | "vertex" 等。
 
void vulkanDispatch (ComputeShader *shader, int groupsX, int groupsY, int groupsZ)
 派发计算着色器(groupsX/Y/Z 为线程组数)。
 
VulkanSequence * vulkanSequenceCreate ()
 Vulkan sequence create.
 
void vulkanSequenceDestroy (VulkanSequence *seq)
 Vulkan sequence destroy.
 
void vulkanSequenceBegin (VulkanSequence *seq)
 Vulkan sequence begin.
 
void vulkanSequenceRecordUpload (VulkanSequence *seq, GpuBuffer *dst, const void *src, uint64_t nbytes, uint64_t dstOffset)
 Vulkan sequence record upload.
 
void vulkanSequenceRecordDownload (VulkanSequence *seq, GpuBuffer *src, GpuBuffer *staging, uint64_t nbytes, uint64_t srcOffset)
 Vulkan sequence record download.
 
void vulkanSequenceRecordDispatch (VulkanSequence *seq, ComputeShader *shader, int groupsX, int groupsY, int groupsZ)
 Vulkan sequence record dispatch.
 
void vulkanSequenceSubmit (VulkanSequence *seq)
 Vulkan sequence submit.
 
SequenceStatus vulkanSequenceSubmitAsync (VulkanSequence *seq)
 Vulkan sequence submit async.
 
SequenceStatus vulkanSequencePoll (VulkanSequence *seq)
 Vulkan sequence poll.
 
SequenceStatus vulkanSequenceWait (VulkanSequence *seq)
 Vulkan sequence wait.
 
SequenceStatus vulkanSequenceStatus (const VulkanSequence *seq)
 Vulkan sequence status.
 
graphics::vulkan::Graphics * requireVulkanGraphics ()
 Resolve live Vulkan Graphics (throws if missing / not initialized).
 
bool vulkanGraphicsReady ()
 True if Vulkan Graphics device is ready.
 
vk::Queue computeQueue (graphics::vulkan::Graphics *vkg)
 Computes queue.
 
vk::CommandPool computeCommandPool (graphics::vulkan::Graphics *vkg)
 Computes command pool.
 
std::vector< uint32_t > loadSpirvFile (const std::string &path)
 Loads spirv file.
 
std::vector< uint32_t > compileComputeGlsl (const std::string &glsl)
 Compiles compute glsl.
 
bool webgpuGpgpuReady ()
 Webgpu gpgpu ready.
 
WebGpuComputeShader * webgpuNewShaderFromWgsl (const std::string &wgsl)
 Webgpu new shader from wgsl.
 
WebGpuComputeShader * webgpuNewShaderFromSpirv (const std::vector< uint32_t > &spv)
 Webgpu new shader from spirv.
 
WebGpuGpuBuffer * webgpuNewBuffer (int byteSize, const std::string &usage)
 Webgpu new buffer.
 
void webgpuDispatch (ComputeShader *shader, int groupsX, int groupsY, int groupsZ)
 Webgpu dispatch.
 
WebGpuSequence * webgpuSequenceCreate ()
 Webgpu sequence create.
 
void webgpuSequenceDestroy (WebGpuSequence *sequence)
 Webgpu sequence destroy.
 
bool webgpuSequenceReady (WebGpuSequence *sequence)
 Webgpu sequence ready.
 
void webgpuSequenceBegin (WebGpuSequence *sequence)
 Webgpu sequence begin.
 
void webgpuSequenceRecordUpload (WebGpuSequence *sequence, GpuBuffer *dst, const void *src, uint64_t nbytes, uint64_t dstOffset)
 Webgpu sequence record upload.
 
void webgpuSequenceRecordDownload (WebGpuSequence *sequence, GpuBuffer *src, GpuBuffer *staging, uint64_t nbytes, uint64_t srcOffset)
 Webgpu sequence record download.
 
void webgpuSequenceRecordDispatch (WebGpuSequence *sequence, ComputeShader *shader, int groupsX, int groupsY, int groupsZ)
 Webgpu sequence record dispatch.
 
SequenceStatus webgpuSequenceSubmitAsync (WebGpuSequence *sequence)
 Webgpu sequence submit async.
 
SequenceStatus webgpuSequencePoll (WebGpuSequence *sequence)
 Webgpu sequence poll.
 
SequenceStatus webgpuSequenceWait (WebGpuSequence *sequence)
 Webgpu sequence wait.
 
SequenceStatus webgpuSequenceStatus (const WebGpuSequence *sequence)
 Webgpu sequence status.
 
void webgpuSequenceSubmit (WebGpuSequence *sequence)
 Webgpu sequence submit.
 

详细描述

Fluids module — interactive surface fluid simulation.

Screen-space fluid surface reconstruction (SSF).

Particles are constrained to mesh SDFs, flow down the surface under tangential gravity, and (later phases) form droplets through cohesion / surface tension. The solver runs on the GPU through the gpgpu module with a CPU reference implementation; the screen-space surface reconstruction pipeline consumes the same particle buffers.

Splats particles into a depth/thickness buffer, bilaterally smooths the depth (curvature-flow style), reconstructs normals from depth gradients and shades the result as either water (Fresnel + refraction look) or mud (diffuse, thickness-attenuated). Projected particle discs carry spherical-cap depth and chord thickness. The CPU reference mirrors the GLSL algorithms in FluidSsfKernels.h; GPU depth and thickness use fixed-point quantization. This disc approximation is not an exact perspective ray/sphere intersection. The GPU path runs on the gpgpu compute queue.

枚举类型说明

◆ SequenceStatus

enum class eve::gpgpu::SequenceStatus : uint8_t
strong

Observable lifecycle state of a reusable GPU command sequence.

枚举值
Idle 
Recording 
Submitted 
Complete 
Failed 

在文件 Sequence.h 第 14 行定义.

函数说明

◆ compileComputeGlsl()

std::vector< uint32_t > eve::gpgpu::compileComputeGlsl ( const std::string &  glsl)

Compiles compute glsl.

在文件 VulkanUtil.cpp 第 88 行定义.

引用了 eve::graphics::compileGlslToSpirv(), eve::graphics::eCompute , 以及 error.

被这些函数引用 compileComputeSpirv().

◆ compileComputeSpirv()

Result< std::vector< uint32_t > > eve::gpgpu::compileComputeSpirv ( const std::string &  source)

Compile GLSL compute source to owning SPIR-V without accessing Graphics or a GPU.

参数
sourceBorrowed until return; independent calls may execute concurrently on worker threads.
返回
Owning words, compilation diagnostic, or Unsupported on WebGPU. No callbacks; each thread retains its own compiler context until thread exit.

在文件 Gpgpu.cpp 第 294 行定义.

引用了 compileComputeGlsl(), eve::Diagnostic::error(), eve::Failed, source , 以及 eve::Unsupported.

被这些函数引用 eve::tensor::onnx_detail::CompilerQueue::enqueue() , 以及 eve::gpgpu::Gpgpu::newShader().

◆ componentFloatCount()

template<typename Comp >
constexpr int eve::gpgpu::componentFloatCount ( )
constexpr

Component float count.

Int.

在文件 EcsGpu.h 第 52 行定义.

◆ computeCommandPool()

vk::CommandPool eve::gpgpu::computeCommandPool ( graphics::vulkan::Graphics *  vkg)

◆ computeQueue()

◆ countViewEntities()

template<typename Base , typename Comp >
int eve::gpgpu::countViewEntities ( )

Count live entities matching View<Base, Comp>.

Returns the number of view entities.

在文件 EcsGpu.h 第 64 行定义.

引用了 n , 以及 view.

◆ createComputeShader()

Result< std::unique_ptr< ComputeShader > > eve::gpgpu::createComputeShader ( const std::vector< uint32_t > &  words)

Create an owning compute pipeline from valid SPIR-V produced by compileComputeSpirv.

参数
wordsBorrowed only until return; must contain a valid compute entry point named main.
返回
Owning shader or a diagnostic; Unsupported on WebGPU.
注解
Device thread only, no concurrent calls/reentrancy or Graphics retirement during the call. The caller must destroy the shader before the active Graphics device retires.

在文件 Gpgpu.cpp 第 307 行定义.

引用了 eve::Diagnostic::error(), eve::Failed, eve::InvalidArgument, eve::Unsupported , 以及 vulkanNewShaderFromSpirv().

被这些函数引用 eve::fluids::OceanGpuSpectrumBuilder::build() , 以及 eve::gpgpu::Gpgpu::newShader().

◆ loadSpirvFile()

std::vector< uint32_t > eve::gpgpu::loadSpirvFile ( const std::string &  path)

Loads spirv file.

在文件 VulkanUtil.cpp 第 81 行定义.

引用了 path.

被这些函数引用 eve::gpgpu::Gpgpu::newShaderFromBytecode().

◆ Module_IMPL()

eve::gpgpu::Module_IMPL ( Gpgpu  ,
new   Gpgpu() 
)

◆ packScriptEntityFloats()

EVENGINE_API_WORLD int eve::gpgpu::packScriptEntityFloats ( ssq::Object  entities,
const std::string &  slot,
ssq::Object  fields,
GpuBuffer *  buf 
)

Pack script ECS entities' component number fields into a GpuBuffer (AoS).

参数
entitiesSquirrel array of entity instances (as returned by eve.view).
slotComponent slot name on the entity, e.g. "pos".
fieldsSquirrel array of field name strings, e.g. ["x", "y"].
bufDestination buffer; must already be large enough for every packed row.
返回
Number of entities packed (0 for an empty view or a non-array argument).
异常
`Exception`when the slot is missing, a field is absent or non-numeric, or the buffer is too small — a partially packed row is never reported as success. @cost 与"实体数 × 字段数"成正比,一次 Squirrel 字段读加一次 buffer 写入;按帧调用时是逐帧 成本,所以 GPU-resident 场景应优先用 ShaderSystem 的区间上传(packEcsFloatsRange), 它只重传变化的那一段。
备注
字段来源是引擎侧那一个权威存储(§9.65 的 readScriptComponentField):登记过的组件 字段在存储里、没登记的在实例槽位里,这里不需要知道区别。行顺序必须与 eve.view 的 稳定顺序(实体 id 升序)一致,因为回读按同一行号寻址。

在文件 EcsScriptPack.cpp 第 98 行定义.

引用了 packScriptEntityFloatsRange() , 以及 slot.

◆ packScriptEntityFloatsRange()

EVENGINE_API_WORLD int eve::gpgpu::packScriptEntityFloatsRange ( ssq::Object  entities,
const std::string &  slot,
ssq::Object  fields,
GpuBuffer *  buf,
int  firstEntity,
int  entityCount 
)

Pack a contiguous entity range into the matching range of an existing buffer.

参数
entitiesSquirrel array of entity instances.
slotComponent slot name on the entity.
fieldsSquirrel array of field name strings.
bufDestination buffer.
firstEntityFirst entity in the stable ECS view.
entityCountNumber of entities to pack; values past the view are clamped.
返回
Number of entities packed.
异常
AspackScriptEntityFloats. @cost 与 entityCount × 字段数 成正比;这是 GPU-resident 的逐帧路径,只应传真正变化的那一段。

在文件 EcsScriptPack.cpp 第 103 行定义.

引用了 entity, f, fields, first, eve::gpgpu::GpuBuffer::getSize(), n, slot, top, v, vm , 以及 eve::gpgpu::GpuBuffer::writeFloat32s().

被这些函数引用 packScriptEntityFloats().

◆ packViewComponent() [1/2]

template<typename Base , typename Comp >
int eve::gpgpu::packViewComponent ( ShaderSystem &  sys,
int  binding 
)

Compatibility overload that uses a temporary staging workspace.

Pack view component.

在文件 EcsGpu.h 第 105 行定义.

引用了 binding.

◆ packViewComponent() [2/2]

template<typename Base , typename Comp >
int eve::gpgpu::packViewComponent ( ShaderSystem &  sys,
int  binding,
EcsGpuWorkspace< Comp > &  workspace 
)

Pack View<Base, Comp> into ShaderSystem binding as AoS floats. Returns entity count (0 if empty).

Pack view component.

Memcpy.

在文件 EcsGpu.h 第 78 行定义.

引用了 binding, n, eve::gpgpu::ShaderSystem::upload() , 以及 view.

◆ packViewComponentRange()

template<typename Base , typename Comp >
int eve::gpgpu::packViewComponentRange ( ShaderSystem &  sys,
int  binding,
int  firstEntity,
int  entityCount,
EcsGpuWorkspace< Comp > &  workspace 
)

Pack a stable contiguous View range into an existing resident buffer. The full buffer must have been allocated by a prior full pack/ensureBuffer.

Pack view component range.

Memcpy.

在文件 EcsGpu.h 第 145 行定义.

引用了 binding, eve::gpgpu::ShaderSystem::uploadRange() , 以及 view.

◆ requireVulkanGraphics()

graphics::vulkan::Graphics * eve::gpgpu::requireVulkanGraphics ( )

Resolve live Vulkan Graphics (throws if missing / not initialized).

在文件 VulkanUtil.cpp 第 44 行定义.

被这些函数引用 eve::gpgpu::VulkanGpuBuffer::downloadBytes(), eve::gpgpu::VulkanSequence::ensureReady(), eve::gpgpu::VulkanGpuBuffer::uploadBytes(), vulkanDispatch(), vulkanNewBuffer() , 以及 vulkanNewShaderFromSpirv().

◆ runViewComponentSystem()

template<typename Base , typename Comp >
int eve::gpgpu::runViewComponentSystem ( ShaderSystem &  sys,
int  binding,
float  dt 
)

Pack + dispatch + unpack a single-component GPU system. Additional bindings must be uploaded by the caller before this helper, or use ShaderSystem manually for multi-buffer systems.

Run view component system.

在文件 EcsGpu.h 第 198 行定义.

引用了 binding, eve::gpgpu::ShaderSystem::dispatch(), dt , 以及 n.

◆ unpackScriptEntityFloats()

EVENGINE_API_WORLD int eve::gpgpu::unpackScriptEntityFloats ( ssq::Object  entities,
const std::string &  slot,
ssq::Object  fields,
GpuBuffer *  buf,
int  entityCount 
)

Inverse of packScriptEntityFloats: write buffer rows back into component fields.

参数
entitiesSquirrel array of entity instances.
slotComponent slot name on the entity.
fieldsSquirrel array of field name strings.
bufSource buffer.
entityCountNumber of entities to write back; should match the pack result.
返回
Number of entities unpacked.
异常
AspackScriptEntityFloats. @cost 与 entityCount × 字段数 成正比,每个字段一次 Squirrel 写入;回读一帧后应当停止继续 在 GPU 上迭代(见 docs/usr/modules/gpgpu.md 的 GPU-resident 说明)。

在文件 EcsScriptPack.cpp 第 172 行定义.

引用了 slot , 以及 unpackScriptEntityFloatsRange().

◆ unpackScriptEntityFloatsRange()

EVENGINE_API_WORLD int eve::gpgpu::unpackScriptEntityFloatsRange ( ssq::Object  entities,
const std::string &  slot,
ssq::Object  fields,
GpuBuffer *  buf,
int  firstEntity,
int  entityCount 
)

Unpack a contiguous buffer range into the matching stable ECS view range.

参数
entitiesSquirrel array of entity instances.
slotComponent slot name on the entity.
fieldsSquirrel array of field name strings.
bufSource buffer.
firstEntityFirst entity and first packed record to read.
entityCountNumber of entities to unpack; values past the view are clamped.
返回
Number of entities unpacked.
异常
AspackScriptEntityFloats. @cost 与 entityCount × 字段数 成正比;配合 requestReadbackRange 时只回读关心的区间。

在文件 EcsScriptPack.cpp 第 177 行定义.

引用了 entity, f, fields, first, eve::gpgpu::GpuBuffer::getSize(), n, eve::gpgpu::GpuBuffer::readFloat32s(), slot, top, v , 以及 vm.

被这些函数引用 unpackScriptEntityFloats().

◆ unpackViewComponent() [1/2]

template<typename Base , typename Comp >
void eve::gpgpu::unpackViewComponent ( ShaderSystem &  sys,
int  binding,
int  count 
)

Compatibility overload that uses a temporary staging workspace.

Unpack view component.

在文件 EcsGpu.h 第 134 行定义.

引用了 binding , 以及 count.

◆ unpackViewComponent() [2/2]

template<typename Base , typename Comp >
void eve::gpgpu::unpackViewComponent ( ShaderSystem &  sys,
int  binding,
int  count,
EcsGpuWorkspace< Comp > &  workspace 
)

Write ShaderSystem binding floats back into View<Base, Comp> (same order as pack). count should be the value returned by packViewComponent.

Unpack view component.

Memcpy.

在文件 EcsGpu.h 第 116 行定义.

引用了 binding, count, eve::gpgpu::ShaderSystem::download() , 以及 view.

◆ unpackViewComponentRange()

template<typename Base , typename Comp >
int eve::gpgpu::unpackViewComponentRange ( ShaderSystem &  sys,
int  binding,
int  firstEntity,
int  entityCount,
EcsGpuWorkspace< Comp > &  workspace 
)

Unpack a stable contiguous resident-buffer range into a matching View range.

Unpack view component range.

Memcpy.

在文件 EcsGpu.h 第 168 行定义.

引用了 binding, count, eve::gpgpu::ShaderSystem::downloadRange() , 以及 view.

◆ vulkanDispatch()

EVENGINE_API_WORLD void eve::gpgpu::vulkanDispatch ( ComputeShader *  shader,
int  groupsX,
int  groupsY,
int  groupsZ 
)

派发计算着色器(groupsX/Y/Z 为线程组数)。

在文件 VulkanGpgpu.cpp 第 124 行定义.

引用了 computeCommandPool(), computeQueue(), device, eve::gpgpu::ComputeShader::kPushConstantBytes, requireVulkanGraphics() , 以及 shader.

被这些函数引用 eve::gpgpu::Gpgpu::dispatch() , 以及 eve::virtualgeometry::vgUpdate().

◆ vulkanGpgpuReady()

bool eve::gpgpu::vulkanGpgpuReady ( )

Vulkan 后端是否就绪(设备/队列可用)。

在文件 VulkanGpgpu.cpp 第 11 行定义.

引用了 vulkanGraphicsReady().

被这些函数引用 eve::gpgpu::Gpgpu::isAvailable().

◆ vulkanGraphicsReady()

bool eve::gpgpu::vulkanGraphicsReady ( )

True if Vulkan Graphics device is ready.

在文件 VulkanUtil.cpp 第 54 行定义.

被这些函数引用 vulkanGpgpuReady().

◆ vulkanNewBuffer()

EVENGINE_API_WORLD GpuBuffer * eve::gpgpu::vulkanNewBuffer ( int  byteSize,
const std::string &  usage 
)

创建 GPU 存储/传输缓冲区;usage 为 "storage" | "vertex" 等。

在文件 VulkanGpgpu.cpp 第 65 行定义.

引用了 b, device, flags, info, requireVulkanGraphics(), result , 以及 usage.

被这些函数引用 eve::gpgpu::Gpgpu::newBuffer(), eve::virtualgeometry::vgReset(), eve::virtualgeometry::vgUpload() , 以及 eve::virtualgeometry::vgUploadUniforms().

◆ vulkanNewShaderFromSpirv()

EVENGINE_API_WORLD ComputeShader * eve::gpgpu::vulkanNewShaderFromSpirv ( const std::vector< uint32_t > &  spv)

◆ vulkanSequenceBegin()

void eve::gpgpu::vulkanSequenceBegin ( VulkanSequence *  seq)

◆ vulkanSequenceCreate()

VulkanSequence * eve::gpgpu::vulkanSequenceCreate ( )

Vulkan sequence create.

在文件 VulkanSequence.cpp 第 31 行定义.

◆ vulkanSequenceDestroy()

void eve::gpgpu::vulkanSequenceDestroy ( VulkanSequence *  seq)

Vulkan sequence destroy.

在文件 VulkanSequence.cpp 第 102 行定义.

引用了 eve::gpgpu::VulkanSequence::destroy().

被这些函数引用 eve::gpgpu::Sequence::~Sequence().

◆ vulkanSequencePoll()

◆ vulkanSequenceRecordDispatch()

◆ vulkanSequenceRecordDownload()

void eve::gpgpu::vulkanSequenceRecordDownload ( VulkanSequence *  seq,
GpuBuffer *  src,
GpuBuffer *  staging,
uint64_t  nbytes,
uint64_t  srcOffset 
)

Vulkan sequence record download.

在文件 VulkanSequence.cpp 第 149 行定义.

引用了 eve::gpgpu::VulkanSequence::commandBuffer , 以及 eve::gpgpu::VulkanSequence::ensureCommandBuffer().

被这些函数引用 eve::gpgpu::Sequence::recordDownload().

◆ vulkanSequenceRecordUpload()

void eve::gpgpu::vulkanSequenceRecordUpload ( VulkanSequence *  seq,
GpuBuffer *  dst,
const void *  src,
uint64_t  nbytes,
uint64_t  dstOffset 
)

◆ vulkanSequenceStatus()

SequenceStatus eve::gpgpu::vulkanSequenceStatus ( const VulkanSequence *  seq)

Vulkan sequence status.

在文件 VulkanSequence.cpp 第 276 行定义.

引用了 Failed , 以及 eve::gpgpu::VulkanSequence::status.

被这些函数引用 eve::gpgpu::Sequence::getStatus().

◆ vulkanSequenceSubmit()

void eve::gpgpu::vulkanSequenceSubmit ( VulkanSequence *  seq)

Vulkan sequence submit.

在文件 VulkanSequence.cpp 第 211 行定义.

引用了 Complete, Failed, vulkanSequenceSubmitAsync() , 以及 vulkanSequenceWait().

被这些函数引用 eve::gpgpu::Sequence::submit().

◆ vulkanSequenceSubmitAsync()

◆ vulkanSequenceWait()

◆ webgpuDispatch()

EVENGINE_API_WORLD void eve::gpgpu::webgpuDispatch ( ComputeShader *  shader,
int  groupsX,
int  groupsY,
int  groupsZ 
)

◆ webgpuGpgpuReady()

bool eve::gpgpu::webgpuGpgpuReady ( )

Webgpu gpgpu ready.

在文件 WebGpuGpgpu.cpp 第 46 行定义.

被这些函数引用 eve::gpgpu::Gpgpu::isAvailable() , 以及 webgpuSequenceReady().

◆ webgpuNewBuffer()

EVENGINE_API_WORLD WebGpuGpuBuffer * eve::gpgpu::webgpuNewBuffer ( int  byteSize,
const std::string &  usage 
)

Webgpu new buffer.

在文件 WebGpuGpgpu.cpp 第 150 行定义.

引用了 b, device , 以及 usage.

被这些函数引用 eve::gpgpu::Gpgpu::newBuffer() , 以及 webgpuDispatch().

◆ webgpuNewShaderFromSpirv()

EVENGINE_API_WORLD WebGpuComputeShader * eve::gpgpu::webgpuNewShaderFromSpirv ( const std::vector< uint32_t > &  spv)

Webgpu new shader from spirv.

在文件 WebGpuGpgpu.cpp 第 144 行定义.

◆ webgpuNewShaderFromWgsl()

EVENGINE_API_WORLD WebGpuComputeShader * eve::gpgpu::webgpuNewShaderFromWgsl ( const std::string &  wgsl)

◆ webgpuSequenceBegin()

void eve::gpgpu::webgpuSequenceBegin ( WebGpuSequence *  sequence)

Webgpu sequence begin.

在文件 WebGpuGpgpu.cpp 第 389 行定义.

引用了 Recording, sequence, Submitted , 以及 webgpuSequenceReady().

◆ webgpuSequenceCreate()

WebGpuSequence * eve::gpgpu::webgpuSequenceCreate ( )

Webgpu sequence create.

在文件 WebGpuGpgpu.cpp 第 381 行定义.

◆ webgpuSequenceDestroy()

void eve::gpgpu::webgpuSequenceDestroy ( WebGpuSequence *  sequence)

Webgpu sequence destroy.

在文件 WebGpuGpgpu.cpp 第 382 行定义.

引用了 sequence, Submitted , 以及 webgpuSequenceWait().

◆ webgpuSequencePoll()

SequenceStatus eve::gpgpu::webgpuSequencePoll ( WebGpuSequence *  sequence)

Webgpu sequence poll.

在文件 WebGpuGpgpu.cpp 第 534 行定义.

引用了 Failed, sequence , 以及 Submitted.

◆ webgpuSequenceReady()

bool eve::gpgpu::webgpuSequenceReady ( WebGpuSequence *  sequence)

Webgpu sequence ready.

在文件 WebGpuGpgpu.cpp 第 387 行定义.

引用了 sequence , 以及 webgpuGpgpuReady().

被这些函数引用 webgpuSequenceBegin() , 以及 webgpuSequenceSubmitAsync().

◆ webgpuSequenceRecordDispatch()

◆ webgpuSequenceRecordDownload()

void eve::gpgpu::webgpuSequenceRecordDownload ( WebGpuSequence *  sequence,
GpuBuffer *  src,
GpuBuffer *  staging,
uint64_t  nbytes,
uint64_t  srcOffset 
)

Webgpu sequence record download.

在文件 WebGpuGpgpu.cpp 第 412 行定义.

引用了 sequence, source , 以及 target.

◆ webgpuSequenceRecordUpload()

void eve::gpgpu::webgpuSequenceRecordUpload ( WebGpuSequence *  sequence,
GpuBuffer *  dst,
const void *  src,
uint64_t  nbytes,
uint64_t  dstOffset 
)

◆ webgpuSequenceStatus()

SequenceStatus eve::gpgpu::webgpuSequenceStatus ( const WebGpuSequence *  sequence)

Webgpu sequence status.

在文件 WebGpuGpgpu.cpp 第 563 行定义.

引用了 Failed , 以及 sequence.

◆ webgpuSequenceSubmit()

void eve::gpgpu::webgpuSequenceSubmit ( WebGpuSequence *  sequence)

Webgpu sequence submit.

在文件 WebGpuGpgpu.cpp 第 567 行定义.

引用了 Complete, sequence, webgpuSequenceSubmitAsync() , 以及 webgpuSequenceWait().

◆ webgpuSequenceSubmitAsync()

◆ webgpuSequenceWait()

SequenceStatus eve::gpgpu::webgpuSequenceWait ( WebGpuSequence *  sequence)

Webgpu sequence wait.

在文件 WebGpuGpgpu.cpp 第 547 行定义.

引用了 Failed, sequence , 以及 Submitted.

被这些函数引用 webgpuSequenceDestroy() , 以及 webgpuSequenceSubmit().