diff options
author | Jakob Bornecrantz <jakob@vmware.com> | 2010-03-11 03:33:03 +0000 |
---|---|---|
committer | Jakob Bornecrantz <jakob@vmware.com> | 2010-03-16 01:06:46 +0000 |
commit | 8b63f9b497c22cb59678588d921699189f8b712f (patch) | |
tree | 35f96ec3a95cada800a834e25db0a7c1effbf592 /src/gallium/winsys/drm/i965 | |
parent | eaee22ac880e431028ac4c6854af1873d5765869 (diff) |
winsys/sw: Add a software winsys layered on a pipe
Diffstat (limited to 'src/gallium/winsys/drm/i965')
-rw-r--r-- | src/gallium/winsys/drm/i965/dri/Makefile | 1 | ||||
-rw-r--r-- | src/gallium/winsys/drm/i965/gem/i965_drm_api.c | 12 |
2 files changed, 12 insertions, 1 deletions
diff --git a/src/gallium/winsys/drm/i965/dri/Makefile b/src/gallium/winsys/drm/i965/dri/Makefile index f7e81eed87..56690769fc 100644 --- a/src/gallium/winsys/drm/i965/dri/Makefile +++ b/src/gallium/winsys/drm/i965/dri/Makefile @@ -7,6 +7,7 @@ PIPE_DRIVERS = \ $(TOP)/src/gallium/state_trackers/dri/libdridrm.a \ $(TOP)/src/gallium/winsys/drm/i965/gem/libi965drm.a \ $(TOP)/src/gallium/drivers/trace/libtrace.a \ + $(TOP)/src/gallium/winsys/drm/sw/libswdrm.a \ $(TOP)/src/gallium/drivers/softpipe/libsoftpipe.a \ $(TOP)/src/gallium/drivers/identity/libidentity.a \ $(TOP)/src/gallium/drivers/i965/libi965.a diff --git a/src/gallium/winsys/drm/i965/gem/i965_drm_api.c b/src/gallium/winsys/drm/i965/gem/i965_drm_api.c index 21e82303f7..2ebc05f47e 100644 --- a/src/gallium/winsys/drm/i965/gem/i965_drm_api.c +++ b/src/gallium/winsys/drm/i965/gem/i965_drm_api.c @@ -10,6 +10,8 @@ #include "trace/tr_drm.h" +#include "../../sw/sw_drm_api.h" + /* * Helper functions */ @@ -108,5 +110,13 @@ struct drm_api i965_libdrm_api = struct drm_api * drm_api_create() { - return trace_drm_create(&i965_libdrm_api); + struct drm_api *api; + + if (api == NULL && debug_get_bool_option("BRW_SOFTPIPE", FALSE)) + api = sw_drm_api_create(&i965_libdrm_api); + + if (api == NULL) + api = &i965_libdrm_api; + + return trace_drm_create(api); } |