Mesa (main): gallium: add size attribute to winsys_handle

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Jun 8 08:12:05 UTC 2022


Module: Mesa
Branch: main
Commit: 8c07d7cbdd2cfc09246d625246bacf8c9c4ecc57
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=8c07d7cbdd2cfc09246d625246bacf8c9c4ecc57

Author: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer at amd.com>
Date:   Wed Jun  1 10:45:09 2022 +0200

gallium: add size attribute to winsys_handle

This is needed at least for the VA-API frontend where the exporter
needs to know the total size of the object.

Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16813>

---

 src/gallium/include/frontend/winsys_handle.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/gallium/include/frontend/winsys_handle.h b/src/gallium/include/frontend/winsys_handle.h
index 30cec27a561..1ebe45ef827 100644
--- a/src/gallium/include/frontend/winsys_handle.h
+++ b/src/gallium/include/frontend/winsys_handle.h
@@ -77,6 +77,12 @@ struct winsys_handle
     * Output for resource_get_handle.
     */
    void *com_obj;
+
+   /**
+    * Total size of the object.
+    * Output for resource_get_handle.
+    */
+   uint64_t size;
 };
 
 #ifdef __cplusplus



More information about the mesa-commit mailing list