From abbbc25b3cc947ed2a264f13663a4082963560e4 Mon Sep 17 00:00:00 2001 From: Julian Orth Date: Mon, 14 Apr 2025 16:30:58 +0200 Subject: [PATCH] single-pixel-buffer: add support for floating-point buffers This allows clients to create buffers with channel values smaller than 0.0 or larger than 1.0. This allows clients to use single pixel buffers with surfaces with an extended color space. The conversion between floating point values and uints can be performed with a memcpy. Signed-off-by: Julian Orth --- .../single-pixel-buffer-v1.xml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/staging/single-pixel-buffer/single-pixel-buffer-v1.xml b/staging/single-pixel-buffer/single-pixel-buffer-v1.xml index b157155..9753385 100644 --- a/staging/single-pixel-buffer/single-pixel-buffer-v1.xml +++ b/staging/single-pixel-buffer/single-pixel-buffer-v1.xml @@ -36,7 +36,7 @@ only be done by creating a new major version of the extension. - + The wp_single_pixel_buffer_manager_v1 interface is a factory for single-pixel buffers. @@ -65,5 +65,19 @@ + + + + The compositor interprets each value as the binary representation of a + IEEE 754 binary32 (also known as float, also known as f32) number. + + The width and height of the buffer are 1. + + + + + + +