Mesa (staging/22.1): wgl: add a flag to determine if running on zink
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Apr 27 02:59:41 UTC 2022
Module: Mesa
Branch: staging/22.1
Commit: 3ae788a9374213684b98a7b4c76df3832323a777
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=3ae788a9374213684b98a7b4c76df3832323a777
Author: Sidney Just <justsid at x-plane.com>
Date: Wed Apr 20 17:47:22 2022 -0400
wgl: add a flag to determine if running on zink
Reviewed-by: Jesse Natalie <jenatali at microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16087>
---
src/gallium/frontends/wgl/stw_device.c | 1 +
src/gallium/frontends/wgl/stw_device.h | 1 +
2 files changed, 2 insertions(+)
diff --git a/src/gallium/frontends/wgl/stw_device.c b/src/gallium/frontends/wgl/stw_device.c
index 8d3b7951f3a..c0a6cb17cc7 100644
--- a/src/gallium/frontends/wgl/stw_device.c
+++ b/src/gallium/frontends/wgl/stw_device.c
@@ -95,6 +95,7 @@ init_screen(const struct stw_winsys *stw_winsys, HDC hdc)
stw_dev->smapi->screen = screen;
stw_dev->screen = screen;
+ stw_dev->zink = !memcmp(screen->get_name(screen), "zink", 4);
stw_dev->max_2d_length = screen->get_param(screen,
PIPE_CAP_MAX_TEXTURE_2D_SIZE);
diff --git a/src/gallium/frontends/wgl/stw_device.h b/src/gallium/frontends/wgl/stw_device.h
index 2ab994f2dc8..b251a17409d 100644
--- a/src/gallium/frontends/wgl/stw_device.h
+++ b/src/gallium/frontends/wgl/stw_device.h
@@ -91,6 +91,7 @@ struct stw_device
struct st_config_options st_options;
bool initialized;
+ bool zink;
};
More information about the mesa-commit
mailing list