buffer_view

WGSL language feature

Availability now
47%
last 30 days, n = 153
Year over year
—
unlocks once the dataset spans a year
Explore

Check navigator.gpu?.wgslLanguageFeatures?.has('buffer_view') before choosing a shader that uses this language feature. It is available automatically when supported; requires buffer_view; documents the dependency and rejects the shader on unsupported implementations. This language token is not a requiredFeatures entry for requestDevice(); any additional device requirements are described below.

A variable of type buffer (runtime-sized, storage only) or buffer<N> (N bytes, in storage, uniform, or workgroup memory) has no element type of its own. bufferView<T>(&b, offset) returns a pointer that accesses the bytes at offset as type T; bufferArrayView does the same for a runtime-sized array, or a structure ending in one, over a given byte size; and bufferLength reports how many bytes are available.

Packed scene data, mixed vertex or index streams, and allocators that hand out sub-ranges of one large binding are the main beneficiaries. Without it, each type needs its own binding, or the shader loads raw u32 words and decodes them with bitcast. In workgroup memory, a single buffer<N> can be divided into several logically separate arrays.

Offsets must respect the alignment of the viewed type in its address space. Misaligned or out-of-range constant and override offsets are rejected when the shader or pipeline is created; a misaligned runtime offset is rounded down, and a runtime view that would extend past the buffer is handled like any other out-of-bounds access. Views cannot contain atomics, and passing buffer pointers into helper functions also needs unrestricted_pointer_parameters.

Availability by month

MonthWith featureEligible reportsAvailability
2026-08 4 238 1.7%
2026-09 61 175 34.9%
2026-10 14 22 63.6%

By browser (last 30 days)

BrowserAvailabilityn
chrome 54.9% 113
edge 76.9% 13
firefox 0.0% 12
safari 0.0% 14

Availability = share of first-party, non-quarantined reports with WebGPU on a hardware (non-fallback) adapter whose browser reports this token in navigator.gpu.wgslLanguageFeatures. This measures language support in the browser, not a GPU hardware capability. Developer-leaning sample. Full methodology.