What the shared Dawn device can render, as plain data. More...
#include <cstdint>#include <string_view>#include <vector>Go to the source code of this file.
Classes | |
| struct | pulp::render::GpuDeviceFeatures |
| Optional device features that change what a format can do. More... | |
| struct | pulp::render::GpuFormatSupport |
| What one format supports on a device. More... | |
| struct | pulp::render::GpuDeviceFacts |
| The facts pick_tier() reads. A test can build one by hand. More... | |
| struct | pulp::render::GpuDeviceCapabilities |
| Rendering capabilities of the shared device. More... | |
Namespaces | |
| namespace | pulp |
| namespace | pulp::render |
Functions | |
| const std::vector< GpuFormat > & | pulp::render::all_gpu_formats () |
| Every format above except undefined, in declaration order. | |
| std::string_view | pulp::render::gpu_format_name (GpuFormat format) |
| WebGPU spelling of a format ("rgba8unorm"), or "undefined". | |
| std::uint32_t | pulp::render::gpu_format_bytes_per_pixel (GpuFormat format) |
| Bytes per texel for color formats, 0 for depth/stencil and undefined (depth texels have no defined CPU layout and cannot be read back). | |
| bool | pulp::render::gpu_format_is_depth (GpuFormat format) |
| True for depth and depth/stencil formats. | |
| GpuFormatSupport | pulp::render::gpu_format_support (GpuFormat format, const GpuDeviceFeatures &features) |
| The WebGPU format table for format, adjusted for features. Pure. | |
| void | pulp::render::fill_format_table (GpuDeviceCapabilities &caps) |
| Fill the format table of caps from caps.facts.features. Pure. | |
| std::string_view | pulp::render::gpu_render_tier_name (GpuRenderTier tier) |
| GpuRenderTier | pulp::render::pick_tier (const GpuDeviceFacts &facts) |
| Pure: the same facts always give the same tier. | |
What the shared Dawn device can render, as plain data.
GpuDeviceCapabilities is filled from the device's wgpu::Limits, its enabled features and the WebGPU format tables. pick_tier() reduces the facts to a coarse rendering tier. Everything here is pure data and pure functions: it names no Dawn type and needs no GPU, so a View can choose a rendering path, and a test can cover that choice, without a device.