Post #1268874
2026-02-19 13:51 UTC
@rtn I am using wgpu-py, which is based wgpu, based on WebGPU.
You can draw into an internal texture of format rgba32float, then use full-range f32 color values. Tone mapping is a separate render pass that translates each pixel down to rgba8uint. It uses a function that compresses the values component by component to the range 0.0-1.0 (or 0-255 when converted to uint8).
1/
Replies (1)
-
@kbob@chaos.social 2026-02-19 13:52
@rtn So you need to enable blending to float32 in an extension device = adapter.request_device(..., required_features=['float32-blendable'], ...) If the extension isn't available, fall back to rgba16float. 2/