diff options
author | Chih-Wei Huang <cwhuang@linux.org.tw> | 2016-06-20 17:34:10 +0800 |
---|---|---|
committer | Mauro Rossi <issor.oruam@gmail.com> | 2016-11-01 20:41:59 +0100 |
commit | 8e91ec27bdbf4b830c9616e3e04b912831c0cf36 (patch) | |
tree | 764a7cb812f5944e235b6d7b35c4c117b50cdf59 /src/gallium/state_trackers | |
parent | 8f951a6f82fafc09d133c89306c8402f38d6d576 (diff) | |
download | external_mesa3d-8e91ec27bdbf4b830c9616e3e04b912831c0cf36.zip external_mesa3d-8e91ec27bdbf4b830c9616e3e04b912831c0cf36.tar.gz external_mesa3d-8e91ec27bdbf4b830c9616e3e04b912831c0cf36.tar.bz2 |
android: more fixes for llvmpipe software rendering
* add dri2_create_from_texture to driswImageExtension
* add dri2FenceExtension to drisw_screen_extensions
Diffstat (limited to 'src/gallium/state_trackers')
-rw-r--r-- | src/gallium/state_trackers/dri/dri2.c | 4 | ||||
-rw-r--r-- | src/gallium/state_trackers/dri/drisw.c | 9 |
2 files changed, 11 insertions, 2 deletions
diff --git a/src/gallium/state_trackers/dri/dri2.c b/src/gallium/state_trackers/dri/dri2.c index 8c058f7..9b51936 100644 --- a/src/gallium/state_trackers/dri/dri2.c +++ b/src/gallium/state_trackers/dri/dri2.c @@ -1173,7 +1173,7 @@ dri2_from_planar(__DRIimage *image, int plane, void *loaderPrivate) return img; } -static __DRIimage * +__DRIimage * dri2_create_from_texture(__DRIcontext *context, int target, unsigned texture, int depth, int level, unsigned *error, void *loaderPrivate) @@ -1551,7 +1551,7 @@ dri2_server_wait_sync(__DRIcontext *_ctx, void *_fence, unsigned flags) /* AFAIK, no driver currently supports parallel context execution. */ } -static __DRI2fenceExtension dri2FenceExtension = { +__DRI2fenceExtension dri2FenceExtension = { .base = { __DRI2_FENCE, 1 }, .create_fence = dri2_create_fence, diff --git a/src/gallium/state_trackers/dri/drisw.c b/src/gallium/state_trackers/dri/drisw.c index 9b62b96..3761dad 100644 --- a/src/gallium/state_trackers/dri/drisw.c +++ b/src/gallium/state_trackers/dri/drisw.c @@ -361,6 +361,11 @@ drisw_update_tex_buffer(struct dri_drawable *drawable, pipe_transfer_unmap(pipe, transfer); } +extern __DRIimage * +dri2_create_from_texture(__DRIcontext *context, int target, unsigned texture, + int depth, int level, unsigned *error, + void *loaderPrivate); + extern __DRIimage *dri2_lookup_egl_image(struct dri_screen *screen, void *handle); extern __DRIimage *dri2_create_image_from_winsys(__DRIscreen *_screen, @@ -370,6 +375,8 @@ extern __DRIimage *dri2_create_image_from_winsys(__DRIscreen *_screen, extern void dri2_destroy_image(__DRIimage *img); +extern __DRI2fenceExtension dri2FenceExtension; + static GLboolean drisw_query_image(__DRIimage *image, int attrib, int *value) { @@ -403,6 +410,7 @@ drisw_query_image(__DRIimage *image, int attrib, int *value) static const __DRIimageExtension driswImageExtension = { .base = { __DRI_IMAGE, 11 }, + .createImageFromTexture = dri2_create_from_texture, .destroyImage = dri2_destroy_image, .queryImage = drisw_query_image, }; @@ -412,6 +420,7 @@ static const __DRIextension *drisw_screen_extensions[] = { &dri2RendererQueryExtension.base, &dri2ConfigQueryExtension.base, &driswImageExtension.base, + &dri2FenceExtension.base, NULL }; |