Expand description
Batching functionality when GPU preprocessing is in use.
Structs§
- Batched
Instance Buffers - The GPU buffers holding the data needed to render batches.
- Batching
Plugin - BinUnpacking
Metadata Index - The index of the metadata corresponding to one bin unpacking job in the
SceneUnpackingBuffers::bin_unpacking_metadatabuffer. - Build
Indirect Parameters Metadata - Metadata that describes how to dispatch the indirect parameters building shader.
- GpuBin
Metadata - Information about each bin in a batch set.
- GpuBin
Unpacking Metadata - GPU-side information needed to unpack bins belonging to a single batch set.
- GpuOcclusion
Culling Work Item Buffers - The work item buffers we use when GPU occlusion culling is in use.
- GpuPreprocessing
Support - Records whether GPU preprocessing and/or GPU culling are supported on the device.
- GpuUniform
Allocation Metadata - Information needed to allocate
MeshUniforms on the GPU. - Indirect
Batch Set - A structure, shared between CPU and GPU, that holds the number of on-GPU indirect draw commands for each batch set.
- Indirect
Parameters Buffers - The buffers containing all the information that indirect draw commands
(
multi_draw_indirect,multi_draw_indirect_count) use to draw the scene. - Indirect
Parameters Buffers Settings - Configuration for
IndirectParametersBuffers. - Indirect
Parameters Build Job - A GPU type that specifies the range of batches that each
build_indirect_paramsshader invocation is to process. - Indirect
Parameters Build Jobs - A resource, part of the render world, that stores the GPU buffer that specifies all the batch ranges that all invocations of the indirect parameters building shader are to process.
- Indirect
Parameters Indexed - The
wgpuindirect parameters structure that specifies a GPU draw command. - Indirect
Parameters Metadata - A structure, written and read on GPU, that records how many instances of each mesh are actually to be drawn.
- Indirect
Parameters NonIndexed - The
wgpuindirect parameters structure that specifies a GPU draw command. - Instance
Input Uniform Buffer - Holds the GPU buffer of instance input data, which is the data about each mesh instance that the CPU provides.
- Late
Preprocess Work Item Indirect Parameters - A GPU-side data structure that stores the number of workgroups to dispatch for the second phase of GPU occlusion culling.
- Mesh
Class Build Indirect Parameters Metadata - Metadata that describes how to dispatch the indirect parameters building shader for a single combination of render phase, view, and mesh class (indexed or non-indexed).
- Mesh
Class Indirect Parameters Buffers - The buffers containing all the information that indirect draw commands use to draw the scene, for a single mesh class (indexed or non-indexed), for a single phase.
- Phase
Batched Instance Buffers - The GPU buffers holding the data needed to render batches for a single phase.
- Phase
Build Indirect Parameters Metadata - Metadata that describes how to dispatch the indirect parameters building shader for a single render phase in a single view.
- Phase
Indirect Parameters Buffers - The buffers containing all the information that indirect draw commands use to draw the scene, for a single phase.
- Preprocess
Work Item - One invocation of the preprocessing shader: i.e. one mesh instance in a view.
- Previous
Instance Input Uniform Buffer - Stores the input uniforms for the previous frame.
- Scene
Unpacking Buffers - A resource, part of the render world, that holds all GPU buffers used for the bin unpacking and uniform allocation shaders.
- Scene
Unpacking Buffers Key - A key used to look up the bin unpacking buffers for a specific phase of a specific view.
- Scene
Unpacking Job - CPU-side information needed to construct the bind groups and issue the
dispatch for the
unpack_binsandallocate_uniformsshaders, for a single batch set. - Uniform
Allocation Metadata Index - The index of the metadata corresponding to one uniform allocation job in the
SceneUnpackingBuffers::uniform_allocation_metadatabuffer. - Untyped
Phase Batched Instance Buffers - The GPU buffers holding the data needed to render batches for a single phase, without a type parameter for that phase.
- Untyped
Phase Indirect Parameters Buffers - The buffers containing all the information that indirect draw commands use to draw the scene, for a single phase.
- View
Build Indirect Parameters Metadata - Metadata that describes how to dispatch the indirect parameters building shader for a single view.
- View
Phase Scene Unpacking Buffers - GPU buffers for the bin unpacking shader that are specific to each phase of each view.
Enums§
- GpuPreprocessing
Mode - The amount of GPU preprocessing (compute and indirect draw) that we do.
- Preprocess
Work Item Buffers - The buffer of GPU preprocessing work items for a single view.
Traits§
- Buffer
Data Input - A trait that defines the data that we supply to the GPU for a single mesh instance (2D or 3D).
- Mesh
Class Indirect Parameters - GPU-side indirect draw parameters for either indexed or non-indexed meshes.
Functions§
- batch_
and_ prepare_ binned_ render_ phase - Creates batches for a render phase that uses bins.
- batch_
and_ prepare_ sorted_ render_ phase - Batch the items in a sorted render phase, when GPU instance buffer building is in use. This means comparing metadata needed to draw each phase item and trying to combine the draws into a batch.
- clear_
batched_ gpu_ instance_ buffers - A system that runs early in extraction and clears out all the
BatchedInstanceBuffersfor the frame. - clear_
indirect_ parameters_ buffers - clear_
scene_ unpacking_ buffers - Clears out the
SceneUnpackingBuffersin preparation for a new frame. - collect_
buffers_ for_ phase - A system that gathers up the per-phase GPU buffers and inserts them into the
BatchedInstanceBuffersandIndirectParametersBufferstables. - delete_
old_ work_ item_ buffers - A system that removes GPU preprocessing work item buffers that correspond to
deleted
ExtractedViews. - get_
or_ create_ work_ item_ buffer - Returns the set of work item buffers for the given view, first creating it if necessary.
- init_
work_ item_ buffers - Initializes work item buffers for a phase in preparation for a new frame.
- prepare_
indirect_ parameters_ build_ jobs - A system, part of the render world, that gathers up the batch ranges from
IndirectParametersBuffersand prepares theBuildIndirectParametersMetadatathat describes the range of batches that each indirect parameters building shader invocation is to process. - write_
batched_ instance_ buffers - A system that writes all instance buffers to the GPU.
- write_
binned_ instance_ buffers - Writes the bin data for each render phase to the GPU.
- write_
indirect_ parameters_ buffers - write_
indirect_ parameters_ build_ jobs - A render-world system that writes the dynamic uniform buffer containing all
IndirectParametersBuildJobs to the GPU.