vulkan: Improve the docs for vk_subpass_info
Reviewed-by: Danylo Piliaiev <dpiliaiev@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17858>
This commit is contained in:

committed by
Marge Bot

parent
378b398da7
commit
3225d60685
@@ -21,9 +21,31 @@ When creating a pipeline, the
|
||||
:cpp:func:`vk_graphics_pipeline_state_fill()` function can be used to
|
||||
gather all of the state from the core structures as well as various `pNext`
|
||||
chains into a single state structure. Whenever an extension struct is
|
||||
missing, a reasonable default value is provided whenever possible. The
|
||||
usual flow for creating a full graphics pipeline (not library) looks like
|
||||
this:
|
||||
missing, a reasonable default value is provided whenever possible.
|
||||
|
||||
|
||||
:cpp:func:`vk_graphics_pipeline_state_fill()` automatically handles both
|
||||
the render pass and dynamic rendering. For drivers which use
|
||||
:cpp:struct:`vk_render_pass`, the :cpp:struct:`vk_render_pass_state`
|
||||
structure will be populated as if for dynamic rendering, regardless of
|
||||
which path is used. Drivers which use their own render pass structure
|
||||
should parse the render pass, if available, and pass a
|
||||
:cpp:struct:`vk_subpass_info` into
|
||||
:cpp:func:`vk_graphics_pipeline_state_fill()` with the relevant information
|
||||
from the specified subpass. If a render pass is available,
|
||||
:cpp:struct:`vk_render_pass_state` will be populated with the
|
||||
:cpp:type:`VkRenderPass` handle and subpass index as well as the
|
||||
information from the :cpp:struct:`vk_render_pass_state`. If dynamic
|
||||
rendering is used or the driver does not provide a
|
||||
:cpp:struct:`vk_subpass_info` structure, :cpp:struct:`vk_render_pass_state`
|
||||
structure will be populated for dynamic rendering, including color, depth,
|
||||
and stencil attachment formats.
|
||||
|
||||
.. doxygenstruct:: vk_subpass_info
|
||||
:members:
|
||||
|
||||
The usual flow for creating a full graphics pipeline (not library) looks
|
||||
like this:
|
||||
|
||||
.. code-block:: c
|
||||
|
||||
|
@@ -746,7 +746,16 @@ struct vk_graphics_pipeline_state {
|
||||
* we can get this information ourselves.
|
||||
*/
|
||||
struct vk_subpass_info {
|
||||
/** VkSubpassDescription2::viewMask */
|
||||
uint32_t view_mask;
|
||||
|
||||
/**
|
||||
* Aspects of all attachments used as color or depth/stencil attachments
|
||||
* in the subpass. Input and resolve attachments should not be considered
|
||||
* when computing the attachments aspect mask. This is used to determine
|
||||
* whether or not depth/stencil and color blend state are required for a
|
||||
* pipeline.
|
||||
*/
|
||||
VkImageAspectFlags attachment_aspects;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user