summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorChia-I Wu <[email protected]>2010-11-17 23:56:42 +0800
committerChia-I Wu <[email protected]>2010-11-18 11:56:00 +0800
commit28105471afce634df6c35ef14b198fe6e3684c00 (patch)
tree93e1d33db4233e8165e03524e98fd15a39b49d87 /src/gallium
parentcc5c908d7deab59f3512e1a5762fd058c4ae5940 (diff)
gallium: Add st_api::name.
It is the name of the rendering API. This field is informative.
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/include/state_tracker/st_api.h5
-rw-r--r--src/gallium/state_trackers/vega/Makefile3
-rw-r--r--src/gallium/state_trackers/vega/SConscript3
-rw-r--r--src/gallium/state_trackers/vega/vg_manager.c1
4 files changed, 12 insertions, 0 deletions
diff --git a/src/gallium/include/state_tracker/st_api.h b/src/gallium/include/state_tracker/st_api.h
index 21e2165ed9e..c73a53db330 100644
--- a/src/gallium/include/state_tracker/st_api.h
+++ b/src/gallium/include/state_tracker/st_api.h
@@ -402,6 +402,11 @@ struct st_manager
struct st_api
{
/**
+ * The name of the rendering API. This is informative.
+ */
+ const char *name;
+
+ /**
* The supported rendering API.
*/
enum st_api_type api;
diff --git a/src/gallium/state_trackers/vega/Makefile b/src/gallium/state_trackers/vega/Makefile
index e0a87151c43..0543fac0946 100644
--- a/src/gallium/state_trackers/vega/Makefile
+++ b/src/gallium/state_trackers/vega/Makefile
@@ -9,6 +9,9 @@ LIBRARY_INCLUDES = \
-I$(TOP)/include \
-I$(TOP)/src/mapi
+LIBRARY_DEFINES = \
+ -DVEGA_VERSION_STRING=\"$(MESA_VERSION)\"
+
C_SOURCES = \
api.c \
api_context.c \
diff --git a/src/gallium/state_trackers/vega/SConscript b/src/gallium/state_trackers/vega/SConscript
index a25b8474e4d..a62783ab18e 100644
--- a/src/gallium/state_trackers/vega/SConscript
+++ b/src/gallium/state_trackers/vega/SConscript
@@ -8,6 +8,9 @@ env = env.Clone()
env.Append(CPPPATH = [
'#/src/mapi',
])
+env.Append(CPPDEFINES = [
+ 'VEGA_VERSION_STRING=',
+])
vega_sources = [
'api.c',
diff --git a/src/gallium/state_trackers/vega/vg_manager.c b/src/gallium/state_trackers/vega/vg_manager.c
index 232deefa166..bb15ec024f2 100644
--- a/src/gallium/state_trackers/vega/vg_manager.c
+++ b/src/gallium/state_trackers/vega/vg_manager.c
@@ -535,6 +535,7 @@ vg_api_destroy(struct st_api *stapi)
}
static const struct st_api vg_api = {
+ "Vega " VEGA_VERSION_STRING,
ST_API_OPENVG,
ST_PROFILE_DEFAULT_MASK,
vg_api_destroy,