## C Specification

The VkPipelineDiscardRectangleStateCreateInfoEXT structure is defined as:

// Provided by VK_EXT_discard_rectangles
VkStructureType                                  sType;
const void*                                      pNext;
} VkPipelineDiscardRectangleStateCreateInfoEXT;

## Members

• sType is the type of this structure.

• pNext is NULL or a pointer to a structure extending this structure.

• flags is reserved for future use.

• discardRectangleMode is a VkDiscardRectangleModeEXT value determining whether the discard rectangle test is inclusive or exclusive.

• discardRectangleCount is the number of discard rectangles to use.

• pDiscardRectangles is a pointer to an array of VkRect2D structures defining discard rectangles.

## Description

If the VK_DYNAMIC_STATE_DISCARD_RECTANGLE_EXT dynamic state is enabled for a pipeline, the pDiscardRectangles member is ignored.

When this structure is included in the pNext chain of VkGraphicsPipelineCreateInfo, it defines parameters of the discard rectangle test. If this structure is not included in the pNext chain, it is equivalent to specifying this structure with a discardRectangleCount of 0.

Valid Usage
discardRectangleCount must be less than or equal to VkPhysicalDeviceDiscardRectanglePropertiesEXT::maxDiscardRectangles

Valid Usage (Implicit)
sType must be VK_STRUCTURE_TYPE_PIPELINE_DISCARD_RECTANGLE_STATE_CREATE_INFO_EXT

flags must be 0

discardRectangleMode must be a valid VkDiscardRectangleModeEXT value