On Thu, Jun 14, 2018 at 7:52 PM, Keith Packard <kei...@keithp.com> wrote:

> This extension is required to support EXT_display_control as it offers
> a way to query whether the vblank counter is supported.
>
> v2: Thanks to kisak
>
>     Fix spelling of VkSurfaceCapabilities2EXT in wsi_common_wayland.c,
>     it was using ext instead of EXT.
>
>     Fix spelling of VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_2_EXT
>
> v3: Fix wayland WSI, regularize spelling
>
>     Misspelled 'surface' in get_capabilities2ext
>     Remove extra _ from get_capabilities_2ext in a couple of places
>
> v4: Adopt Jason Ekstrand's coding conventions
>
>     Declare variables at first use, eliminate extra whitespace
>     between types and names. Wrap lines to 80 columns.
>
>     Suggested-by: Jason Ekstrand <jason.ekstr...@intel.com>
>
> Signed-off-by: Keith Packard <kei...@keithp.com>
> ---
>  src/vulkan/wsi/wsi_common.c         | 12 ++++++++++++
>  src/vulkan/wsi/wsi_common.h         |  6 ++++++
>  src/vulkan/wsi/wsi_common_display.c | 27 +++++++++++++++++++++++++++
>  src/vulkan/wsi/wsi_common_private.h |  3 +++
>  src/vulkan/wsi/wsi_common_wayland.c | 27 +++++++++++++++++++++++++++
>  src/vulkan/wsi/wsi_common_x11.c     | 27 +++++++++++++++++++++++++++
>  6 files changed, 102 insertions(+)
>
> diff --git a/src/vulkan/wsi/wsi_common_private.h
> b/src/vulkan/wsi/wsi_common_private.h
> index 3d502b9fc9d..b97d2d8ba06 100644
> --- a/src/vulkan/wsi/wsi_common_private.h
> +++ b/src/vulkan/wsi/wsi_common_private.h
> @@ -109,6 +109,9 @@ struct wsi_interface {
>     VkResult (*get_capabilities2)(VkIcdSurfaceBase *surface,
>                                   const void *info_next,
>                                   VkSurfaceCapabilities2KHR*
> pSurfaceCapabilities);
> +   VkResult (*get_capabilities2ext)(VkIcdSurfaceBase *surface,
> +                                    VkSurfaceCapabilities2EXT*
> +                                    pSurfaceCapabilities);
>

I really don't like adding a third get_capabilities hook.  An alternative
way to do this would be to add a pseud-extension which allows you do get he
extra bit of data with a chain-in on vkGetSurfaceCapabilities2KHR.  I sent
two patches which do just that.  If you like them, I'm happy do do the
reabase for you if you'd like.

--Jason
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to