[Mesa-dev] [PATCH v3] gallium: introduce dmabuf format and modifier querying
Lucas Stach
l.stach at pengutronix.de
Fri Apr 28 10:44:26 UTC 2017
Am Mittwoch, den 26.04.2017, 17:49 +0530 schrieb Varad Gautam:
> allows drivers to be queried for supported formats and format
> modifiers for EGL_EXT_image_dma_buf_import_modifiers. drivers that
> implement format/modifier queries must advertise these under
> PIPE_CAP_QUERY_DMABUF_ATTRIBS.
>
> v2: rebase to master.
> v3: drivers must return false on query failure.
>
> Signed-off-by: Varad Gautam <varad.gautam at collabora.com>
> ---
> src/gallium/docs/source/screen.rst | 2 ++
> src/gallium/drivers/freedreno/freedreno_screen.c | 1 +
> src/gallium/drivers/i915/i915_screen.c | 1 +
> src/gallium/drivers/llvmpipe/lp_screen.c | 1 +
> src/gallium/drivers/nouveau/nv30/nv30_screen.c | 1 +
> src/gallium/drivers/nouveau/nv50/nv50_screen.c | 1 +
> src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 1 +
> src/gallium/drivers/r300/r300_screen.c | 1 +
> src/gallium/drivers/r600/r600_pipe.c | 1 +
> src/gallium/drivers/radeonsi/si_pipe.c | 1 +
> src/gallium/drivers/softpipe/sp_screen.c | 1 +
> src/gallium/drivers/svga/svga_screen.c | 1 +
> src/gallium/drivers/swr/swr_screen.cpp | 1 +
> src/gallium/drivers/vc4/vc4_screen.c | 1 +
> src/gallium/drivers/virgl/virgl_screen.c | 1 +
> src/gallium/include/pipe/p_defines.h | 1 +
> src/gallium/include/pipe/p_screen.h | 21 +++++++++++++++++++++
> 17 files changed, 38 insertions(+)
>
> diff --git a/src/gallium/docs/source/screen.rst b/src/gallium/docs/source/screen.rst
> index bb2803a..c723c75 100644
> --- a/src/gallium/docs/source/screen.rst
> +++ b/src/gallium/docs/source/screen.rst
> @@ -389,6 +389,8 @@ The integer capabilities:
> * ``PIPE_CAP_TGSI_TES_LAYER_VIEWPORT``: Whether ``TGSI_SEMANTIC_LAYER`` and
> ``TGSI_SEMANTIC_VIEWPORT_INDEX`` are supported as tessellation evaluation
> shader outputs.
> +* ``PIPE_CAP_QUERY_DMABUF_ATTRIBS``: Whether the driver supports querying for
> + supported dmabuf formats and format modifiers.
Do we really need a CAP for this? Couldn't the state tracker just check
for the presence of the query_dmabuf_formats and query_dmabuf_modifiers
entrypoints?
Regards,
Lucas
More information about the mesa-dev
mailing list