[{"data":1,"prerenderedAt":502},["ShallowReactive",2],{"Ul1BUEkmsu":3},{"title":4,"description":5,"parent":6,"cmd_buf_level":7,"render_pass_scope":10,"supported_queue_types":11,"tasks":13,"type":15,"xrefs":16,"body":17,"_type":501,"_id":4},"vkCmdSetDiscardRectangleEnableEXT","Enable discard rectangles dynamically for a command buffer","VK_EXT_discard_rectangles",[8,9],"primary","secondary","both",[12],"graphics",[14],"state","protos",[],{"type":18,"children":19,"toc":499},"root",[20,37,218,243,301,351,447,493],{"type":21,"tag":22,"props":23,"children":24},"element","p",{},[25,28,35],{"type":26,"value":27},"text","To ",{"type":21,"tag":29,"props":30,"children":32},"a",{"href":31},"/chapters/pipelines#pipelines-dynamic-state",[33],{"type":26,"value":34},"dynamically set",{"type":26,"value":36}," whether discard rectangles\nare enabled, call:",{"type":21,"tag":38,"props":39,"children":40},"code-group",{},[41,117],{"type":21,"tag":42,"props":43,"children":49},"pre",{"className":44,"code":45,"filename":46,"language":47,"meta":48,"style":48},"language-c shiki shiki-themes github-light-default github-dark-default","void vkCmdSetDiscardRectangleEnableEXT(\n VkCommandBuffer commandBuffer,\n VkBool32 discardRectangleEnable);\n","C","c","",[50],{"type":21,"tag":51,"props":52,"children":53},"code",{"__ignoreMap":48},[54,78,98],{"type":21,"tag":55,"props":56,"children":59},"span",{"class":57,"line":58},"line",1,[60,66,72],{"type":21,"tag":55,"props":61,"children":63},{"style":62},"--shiki-default:#CF222E;--shiki-dark:#FF7B72",[64],{"type":26,"value":65},"void",{"type":21,"tag":55,"props":67,"children":69},{"style":68},"--shiki-default:#8250DF;--shiki-dark:#D2A8FF",[70],{"type":26,"value":71}," vkCmdSetDiscardRectangleEnableEXT",{"type":21,"tag":55,"props":73,"children":75},{"style":74},"--shiki-default:#1F2328;--shiki-dark:#E6EDF3",[76],{"type":26,"value":77},"(\n",{"type":21,"tag":55,"props":79,"children":81},{"class":57,"line":80},2,[82,87,93],{"type":21,"tag":55,"props":83,"children":84},{"style":74},[85],{"type":26,"value":86}," VkCommandBuffer ",{"type":21,"tag":55,"props":88,"children":90},{"style":89},"--shiki-default:#953800;--shiki-dark:#FFA657",[91],{"type":26,"value":92},"commandBuffer",{"type":21,"tag":55,"props":94,"children":95},{"style":74},[96],{"type":26,"value":97},",\n",{"type":21,"tag":55,"props":99,"children":101},{"class":57,"line":100},3,[102,107,112],{"type":21,"tag":55,"props":103,"children":104},{"style":74},[105],{"type":26,"value":106}," VkBool32 ",{"type":21,"tag":55,"props":108,"children":109},{"style":89},[110],{"type":26,"value":111},"discardRectangleEnable",{"type":21,"tag":55,"props":113,"children":114},{"style":74},[115],{"type":26,"value":116},");\n",{"type":21,"tag":42,"props":118,"children":123},{"className":119,"code":120,"filename":121,"language":122,"meta":48,"style":48},"language-rs shiki shiki-themes github-light-default github-dark-default","pub fn cmd_set_discard_rectangle_enable_ext(\n command_buffer: vk::CommandBuffer,\n discard_rectangle_enable: vk::Bool32,\n);\n","Rust","rs",[124],{"type":21,"tag":51,"props":125,"children":126},{"__ignoreMap":48},[127,149,181,210],{"type":21,"tag":55,"props":128,"children":129},{"class":57,"line":58},[130,135,140,145],{"type":21,"tag":55,"props":131,"children":132},{"style":62},[133],{"type":26,"value":134},"pub",{"type":21,"tag":55,"props":136,"children":137},{"style":62},[138],{"type":26,"value":139}," fn",{"type":21,"tag":55,"props":141,"children":142},{"style":68},[143],{"type":26,"value":144}," cmd_set_discard_rectangle_enable_ext",{"type":21,"tag":55,"props":146,"children":147},{"style":74},[148],{"type":26,"value":77},{"type":21,"tag":55,"props":150,"children":151},{"class":57,"line":80},[152,157,162,167,172,177],{"type":21,"tag":55,"props":153,"children":154},{"style":74},[155],{"type":26,"value":156}," command_buffer",{"type":21,"tag":55,"props":158,"children":159},{"style":62},[160],{"type":26,"value":161},":",{"type":21,"tag":55,"props":163,"children":164},{"style":89},[165],{"type":26,"value":166}," vk",{"type":21,"tag":55,"props":168,"children":169},{"style":62},[170],{"type":26,"value":171},"::",{"type":21,"tag":55,"props":173,"children":174},{"style":89},[175],{"type":26,"value":176},"CommandBuffer",{"type":21,"tag":55,"props":178,"children":179},{"style":74},[180],{"type":26,"value":97},{"type":21,"tag":55,"props":182,"children":183},{"class":57,"line":100},[184,189,193,197,201,206],{"type":21,"tag":55,"props":185,"children":186},{"style":74},[187],{"type":26,"value":188}," discard_rectangle_enable",{"type":21,"tag":55,"props":190,"children":191},{"style":62},[192],{"type":26,"value":161},{"type":21,"tag":55,"props":194,"children":195},{"style":89},[196],{"type":26,"value":166},{"type":21,"tag":55,"props":198,"children":199},{"style":62},[200],{"type":26,"value":171},{"type":21,"tag":55,"props":202,"children":203},{"style":89},[204],{"type":26,"value":205},"Bool32",{"type":21,"tag":55,"props":207,"children":208},{"style":74},[209],{"type":26,"value":97},{"type":21,"tag":55,"props":211,"children":213},{"class":57,"line":212},4,[214],{"type":21,"tag":55,"props":215,"children":216},{"style":74},[217],{"type":26,"value":116},{"type":21,"tag":219,"props":220,"children":221},"ul",{},[222,233],{"type":21,"tag":223,"props":224,"children":225},"li",{},[226,231],{"type":21,"tag":51,"props":227,"children":229},{"className":228},[],[230],{"type":26,"value":92},{"type":26,"value":232}," is the command buffer into which the command will be\nrecorded.",{"type":21,"tag":223,"props":234,"children":235},{},[236,241],{"type":21,"tag":51,"props":237,"children":239},{"className":238},[],[240],{"type":26,"value":111},{"type":26,"value":242}," specifies whether discard rectangles are\nenabled or not.",{"type":21,"tag":22,"props":244,"children":245},{},[246,248,254,256,262,264,270,271,277,279,285,286,292,294,299],{"type":26,"value":247},"This command sets the discard rectangle enable for subsequent drawing\ncommands\nwhen drawing using ",{"type":21,"tag":29,"props":249,"children":251},{"href":250},"/chapters/shaders#shaders-objects",[252],{"type":26,"value":253},"shader objects",{"type":26,"value":255},", or\nwhen the graphics pipeline is created with\n",{"type":21,"tag":51,"props":257,"children":259},{"className":258},[],[260],{"type":26,"value":261},"VK_DYNAMIC_STATE_DISCARD_RECTANGLE_ENABLE_EXT",{"type":26,"value":263}," set in\n",{"type":21,"tag":29,"props":265,"children":267},{"href":266},"/man/VkPipelineDynamicStateCreateInfo",[268],{"type":26,"value":269},"VkPipelineDynamicStateCreateInfo",{"type":26,"value":171},{"type":21,"tag":51,"props":272,"children":274},{"className":273},[],[275],{"type":26,"value":276},"pDynamicStates",{"type":26,"value":278},".\nOtherwise, this state is implied by the\n",{"type":21,"tag":29,"props":280,"children":282},{"href":281},"/man/VkPipelineDiscardRectangleStateCreateInfoEXT",[283],{"type":26,"value":284},"VkPipelineDiscardRectangleStateCreateInfoEXT",{"type":26,"value":171},{"type":21,"tag":51,"props":287,"children":289},{"className":288},[],[290],{"type":26,"value":291},"discardRectangleCount",{"type":26,"value":293},"\nvalue used to create the currently active pipeline, where a non-zero\n",{"type":21,"tag":51,"props":295,"children":297},{"className":296},[],[298],{"type":26,"value":291},{"type":26,"value":300}," implicitly enables discard rectangles, otherwise\nthey are disabled.",{"type":21,"tag":302,"props":303,"children":305},"validity-group",{"name":304},"Valid Usage",[306],{"type":21,"tag":307,"props":308,"children":310},"validity-field",{"name":309},"VUID-vkCmdSetDiscardRectangleEnableEXT-specVersion-07851",[311],{"type":21,"tag":22,"props":312,"children":313},{},[314,316,321,323,328,330,333,335,341,343,349],{"type":26,"value":315},"The ",{"type":21,"tag":29,"props":317,"children":319},{"href":318},"/extensions/VK_EXT_discard_rectangles",[320],{"type":26,"value":6},{"type":26,"value":322}," extension ",{"type":21,"tag":324,"props":325,"children":327},"normative",{"type":326},"must",[],{"type":26,"value":329}," be enabled, and\nthe implementation ",{"type":21,"tag":324,"props":331,"children":332},{"type":326},[],{"type":26,"value":334}," support at least ",{"type":21,"tag":51,"props":336,"children":338},{"className":337},[],[339],{"type":26,"value":340},"specVersion",{"type":26,"value":342}," ",{"type":21,"tag":51,"props":344,"children":346},{"className":345},[],[347],{"type":26,"value":348},"2",{"type":26,"value":350}," of this\nextension",{"type":21,"tag":302,"props":352,"children":354},{"name":353},"Valid Usage (Implicit)",[355,381,405,433],{"type":21,"tag":307,"props":356,"children":358},{"name":357},"VUID-vkCmdSetDiscardRectangleEnableEXT-commandBuffer-parameter",[359],{"type":21,"tag":22,"props":360,"children":361},{},[362,367,368,371,373,379],{"type":21,"tag":51,"props":363,"children":365},{"className":364},[],[366],{"type":26,"value":92},{"type":26,"value":342},{"type":21,"tag":324,"props":369,"children":370},{"type":326},[],{"type":26,"value":372}," be a valid ",{"type":21,"tag":29,"props":374,"children":376},{"href":375},"/man/VkCommandBuffer",[377],{"type":26,"value":378},"VkCommandBuffer",{"type":26,"value":380}," handle",{"type":21,"tag":307,"props":382,"children":384},{"name":383},"VUID-vkCmdSetDiscardRectangleEnableEXT-commandBuffer-recording",[385],{"type":21,"tag":22,"props":386,"children":387},{},[388,393,394,397,399],{"type":21,"tag":51,"props":389,"children":391},{"className":390},[],[392],{"type":26,"value":92},{"type":26,"value":342},{"type":21,"tag":324,"props":395,"children":396},{"type":326},[],{"type":26,"value":398}," be in the ",{"type":21,"tag":29,"props":400,"children":402},{"href":401},"/chapters/commandbuffers#commandbuffers-lifecycle",[403],{"type":26,"value":404},"recording state",{"type":21,"tag":307,"props":406,"children":408},{"name":407},"VUID-vkCmdSetDiscardRectangleEnableEXT-commandBuffer-cmdpool",[409],{"type":21,"tag":22,"props":410,"children":411},{},[412,413,419,421,426,428,431],{"type":26,"value":315},{"type":21,"tag":51,"props":414,"children":416},{"className":415},[],[417],{"type":26,"value":418},"VkCommandPool",{"type":26,"value":420}," that ",{"type":21,"tag":51,"props":422,"children":424},{"className":423},[],[425],{"type":26,"value":92},{"type":26,"value":427}," was allocated from ",{"type":21,"tag":324,"props":429,"children":430},{"type":326},[],{"type":26,"value":432}," support graphics operations",{"type":21,"tag":307,"props":434,"children":436},{"name":435},"VUID-vkCmdSetDiscardRectangleEnableEXT-videocoding",[437],{"type":21,"tag":22,"props":438,"children":439},{},[440,442,445],{"type":26,"value":441},"This command ",{"type":21,"tag":324,"props":443,"children":444},{"type":326},[],{"type":26,"value":446}," only be called outside of a video coding scope",{"type":21,"tag":448,"props":449,"children":451},"validity-box",{"name":450},"Host Synchronization",[452],{"type":21,"tag":219,"props":453,"children":454},{},[455,471],{"type":21,"tag":223,"props":456,"children":457},{},[458,460,465,466,469],{"type":26,"value":459},"Host access to ",{"type":21,"tag":51,"props":461,"children":463},{"className":462},[],[464],{"type":26,"value":92},{"type":26,"value":342},{"type":21,"tag":324,"props":467,"children":468},{"type":326},[],{"type":26,"value":470}," be externally synchronized",{"type":21,"tag":223,"props":472,"children":473},{},[474,476,481,482,487,488,491],{"type":26,"value":475},"Host access to the ",{"type":21,"tag":51,"props":477,"children":479},{"className":478},[],[480],{"type":26,"value":418},{"type":26,"value":420},{"type":21,"tag":51,"props":483,"children":485},{"className":484},[],[486],{"type":26,"value":92},{"type":26,"value":427},{"type":21,"tag":324,"props":489,"children":490},{"type":326},[],{"type":26,"value":492}," be externally synchronized\n::",{"type":21,"tag":494,"props":495,"children":496},"style",{},[497],{"type":26,"value":498},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":48,"searchDepth":80,"depth":80,"links":500},[],"markdown",1729612505075]