Skip to content

Commit

Permalink
Add VK_EXT_disable_wayland_color_management
Browse files Browse the repository at this point in the history
Fixes #2307
  • Loading branch information
colinmarc committed Aug 16, 2024
1 parent 59dc3a3 commit 8ecfdd7
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 6 deletions.
31 changes: 31 additions & 0 deletions appendices/VK_EXT_disable_wayland_color_management.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Copyright 2016-2024 The Khronos Group Inc.
//
// SPDX-License-Identifier: CC-BY-4.0

include::{generated}/meta/{refprefix}VK_EXT_disable_wayland_color_management.adoc[]

=== Other Extension Metadata

*Last Modified Date*::
2024-08-16
*IP Status*::
No known IP claims.
*Contributors*::
Colin Marc

=== Description

This extension expands elink:VkWaylandSurfaceCreateFlagsKHR to allow
applications to request that implementations avoid using the
`wp_color_management` protocol when creating or managing the surface.

include::{generated}/interfaces/VK_EXT_disable_wayland_color_management.adoc[]

=== Issues

None.

=== Version History

* Revision 1, 2024-08-16 (Colin Marc)
** Initial draft
3 changes: 3 additions & 0 deletions appendices/VK_KHR_wayland_surface.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,6 @@ an onerous restriction on application developers.
ename:VK_PRESENT_MODE_MAILBOX_KHR.
** Added wording about interactions between flink:vkQueuePresentKHR and
the Wayland requests sent to the compositor.

* Revision 7, 2024-08-16 (Colin Marc)
** Added VkWaylandSurfaceCreateFlagBits.
24 changes: 20 additions & 4 deletions chapters/VK_KHR_wayland_surface/platformCreateSurface_wayland.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ include::{generated}/api/structs/VkWaylandSurfaceCreateInfoKHR.adoc[]
* pname:sType is a elink:VkStructureType value identifying this structure.
* pname:pNext is `NULL` or a pointer to a structure extending this
structure.
* pname:flags is reserved for future use.
* pname:flags is a bitmask of elink:VkWaylandSurfaceCreateFlagBitsKHR
specifying additional surface creation parameters.
* pname:display and pname:surface are pointers to the Wayland
code:wl_display and code:wl_surface to associate the surface with.

Expand Down Expand Up @@ -87,10 +88,25 @@ If the application wishes to synchronize any window changes with a
particular frame, such requests must: be sent to the Wayland display server
prior to calling flink:vkQueuePresentKHR.

[open,refpage='VkWaylandSurfaceCreateFlagsKHR',desc='Reserved for future use',type='flags']
[open,refpage='VkWaylandSurfaceCreateFlagBitsKHR',desc='Bitmask specifying additional parameters for the Wayland surface.',type='enums',xrefs='VkWaylandSurfaceCreateInfoKHR']
--
include::{generated}/api/enums/VkWaylandSurfaceCreateFlagBitsKHR.adoc[]
--

ifdef::VK_EXT_disable_wayland_color_management[]
Possible values of the pname:flags member of
slink:VkWaylandSurfaceCreateInfo are:

* ename:VK_WAYLAND_SURFACE_CREATE_DISABLE_COLOR_MANAGEMENT specifies that the
implementation should avoid using the `wp_color_management` protocol
manage the surface.
endif::VK_EXT_disable_wayland_color_management[]


[open,refpage='VkWaylandSurfaceCreateFlagsKHR',desc='Bitmask of VkWaylandSurfaceCreateFlagBitsKHR',type='flags']
--
include::{generated}/api/flags/VkWaylandSurfaceCreateFlagsKHR.adoc[]

tname:VkWaylandSurfaceCreateFlagsKHR is a bitmask type for setting a mask,
but is currently reserved for future use.
tname:VkWaylandSurfaceCreateFlagsKHR is a bitmask type for setting a mask of
zero or more elink:VkWaylandSurfaceCreateFlagBitsKHR.
--
15 changes: 13 additions & 2 deletions xml/vk.xml
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ typedef void* <name>MTLSharedEvent_id</name>;
<type category="bitmask">typedef <type>VkFlags</type> <name>VkDisplaySurfaceCreateFlagsKHR</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkAndroidSurfaceCreateFlagsKHR</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkViSurfaceCreateFlagsNN</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkWaylandSurfaceCreateFlagsKHR</name>;</type>
<type requires= "VkWaylandSurfaceCreateFlagBitsKHR" category="bitmask">typedef <type>VkFlags</type> <name>VkWaylandSurfaceCreateFlagsKHR</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkWin32SurfaceCreateFlagsKHR</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkXlibSurfaceCreateFlagsKHR</name>;</type>
<type category="bitmask">typedef <type>VkFlags</type> <name>VkXcbSurfaceCreateFlagsKHR</name>;</type>
Expand Down Expand Up @@ -877,6 +877,7 @@ typedef void* <name>MTLSharedEvent_id</name>;
<type name="VkOutOfBandQueueTypeNV" category="enum"/>
<type name="VkPhysicalDeviceSchedulingControlsFlagBitsARM" category="enum"/>
<type name="VkMemoryUnmapFlagBitsKHR" category="enum"/>
<type name="VkWaylandSurfaceCreateFlagBitsKHR" category="enum"/>

<comment>Enumerated types in the header, but not used by the API</comment>
<type name="VkVendorId" category="enum"/>
Expand Down Expand Up @@ -11322,6 +11323,8 @@ typedef void* <name>MTLSharedEvent_id</name>;
</enums>
<enums name="VkMemoryUnmapFlagBitsKHR" type="bitmask">
</enums>
<enums name="VkWaylandSurfaceCreateFlagBitsKHR" type="bitmask">
</enums>

<commands comment="Vulkan command definitions">
<command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY,VK_ERROR_OUT_OF_DEVICE_MEMORY,VK_ERROR_INITIALIZATION_FAILED,VK_ERROR_LAYER_NOT_PRESENT,VK_ERROR_EXTENSION_NOT_PRESENT,VK_ERROR_INCOMPATIBLE_DRIVER">
Expand Down Expand Up @@ -17026,10 +17029,11 @@ typedef void* <name>MTLSharedEvent_id</name>;
</extension>
<extension name="VK_KHR_wayland_surface" number="7" type="instance" depends="VK_KHR_surface" platform="wayland" author="KHR" contact="Jesse Hall @critsec,Ian Elliott @ianelliottus" supported="vulkan" ratified="vulkan">
<require>
<enum value="6" name="VK_KHR_WAYLAND_SURFACE_SPEC_VERSION"/>
<enum value="7" name="VK_KHR_WAYLAND_SURFACE_SPEC_VERSION"/>
<enum value="&quot;VK_KHR_wayland_surface&quot;" name="VK_KHR_WAYLAND_SURFACE_EXTENSION_NAME"/>
<enum offset="0" extends="VkStructureType" name="VK_STRUCTURE_TYPE_WAYLAND_SURFACE_CREATE_INFO_KHR"/>
<type name="VkWaylandSurfaceCreateFlagsKHR"/>
<type name="VkWaylandSurfaceCreateFlagBitsKHR"/>
<type name="VkWaylandSurfaceCreateInfoKHR"/>
<command name="vkCreateWaylandSurfaceKHR"/>
<command name="vkGetPhysicalDeviceWaylandPresentationSupportKHR"/>
Expand Down Expand Up @@ -24640,6 +24644,13 @@ typedef void* <name>MTLSharedEvent_id</name>;
<enum value="&quot;VK_EXT_extension_602&quot;" name="VK_EXT_EXTENSION_602_EXTENSION_NAME"/>
</require>
</extension>
<extension name="VK_EXT_disable_wayland_color_management" number="603" type="instance" depends="VK_KHR_wayland_surface+VK_EXT_swapchain_colorspace" author="EXT" contact="Colin Marc @colinmarc" supported="vulkan">
<require>
<enum value="1" name="VK_EXT_DISABLE_WAYLAND_COLOR_MANAGEMENT_SPEC_VERSION"/>
<enum value="&quot;VK_EXT_disable_wayland_color_management&quot;" name="VK_EXT_DISABLE_WAYLAND_COLOR_MANAGEMENT_EXTENSION_NAME"/>
<enum bitpos="0" extends="VkWaylandSurfaceCreateFlagBitsKHR" name="VK_WAYLAND_SURFACE_CREATE_DISABLE_COLOR_MANAGEMENT"/>
</require>
</extension>
</extensions>
<formats>
<format name="VK_FORMAT_R4G4_UNORM_PACK8" class="8-bit" blockSize="1" texelsPerBlock="1" packed="8">
Expand Down

0 comments on commit 8ecfdd7

Please sign in to comment.