OSDN Git Service

gallium: add BIND flags for R/W buffers and images
authorMarek Olšák <marek.olsak@amd.com>
Sun, 5 Jul 2015 11:51:16 +0000 (13:51 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Thu, 16 Jul 2015 14:52:02 +0000 (16:52 +0200)
commitf9f79d29ce75c681c46bdbac5aa3f19ee1adb93b
treedf4f657bbdfb4c15520fd9fe2cd401b395581e11
parent26222932c013da3688e39dc831179659cc65c39a
gallium: add BIND flags for R/W buffers and images

PIPE_CAPs and TGSI support will be added later. The TGSI support should be
straightforward. We only need to split TGSI_FILE_RESOURCE into TGSI_FILE_IMAGE
and TGSI_FILE_BUFFER, though duplicating all opcodes shouldn't be necessary.

The idea is:
* ARB_shader_image_load_store should use set_shader_images.
* ARB_shader_storage_buffer_object should use set_shader_buffers(slots 0..M-1)
  if M shader storage buffers are supported.
* ARB_shader_atomic_counters should use set_shader_buffers(slots M..N)
  if N-M+1 atomic counter buffers are supported.

PIPE_CAPs can describe various constraints for early DX11 hardware.

Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/gallium/auxiliary/util/u_debug.c
src/gallium/docs/source/screen.rst
src/gallium/drivers/ilo/ilo_resource.c
src/gallium/drivers/nouveau/nouveau_buffer.c
src/gallium/drivers/nouveau/nouveau_screen.c
src/gallium/drivers/nouveau/nv50/nv50_formats.c
src/gallium/include/pipe/p_defines.h