[{"data":1,"prerenderedAt":493},["ShallowReactive",2],{"qAxEqgYtjt":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":492,"_id":4},"vkCmdSetLogicOpEXT","Select which logical operation to apply for blend state dynamically for a command buffer","VK_EXT_extended_dynamic_state2, VK_EXT_shader_object",[8,9],"primary","secondary","both",[12],"graphics",[14],"state","protos",[],{"type":18,"children":19,"toc":490},"root",[20,37,218,243,293,315,438,484],{"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}," the logical operation to\napply for blend state, 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 vkCmdSetLogicOpEXT(\n VkCommandBuffer commandBuffer,\n VkLogicOp logicOp);\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}," vkCmdSetLogicOpEXT",{"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}," VkLogicOp ",{"type":21,"tag":55,"props":108,"children":109},{"style":89},[110],{"type":26,"value":111},"logicOp",{"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_logic_op_ext(\n command_buffer: vk::CommandBuffer,\n logic_op: vk::LogicOp,\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_logic_op_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}," logic_op",{"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},"LogicOp",{"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 the logical operation to apply for blend state.",{"type":21,"tag":22,"props":244,"children":245},{},[246,248,254,256,262,264,270,271,277,279,285,286,291],{"type":26,"value":247},"This command sets the logical operation for blend state for subsequent\ndrawing commands\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_LOGIC_OP_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 specified by the\n",{"type":21,"tag":29,"props":280,"children":282},{"href":281},"/man/VkPipelineColorBlendStateCreateInfo",[283],{"type":26,"value":284},"VkPipelineColorBlendStateCreateInfo",{"type":26,"value":171},{"type":21,"tag":51,"props":287,"children":289},{"className":288},[],[290],{"type":26,"value":111},{"type":26,"value":292}," value used to\ncreate the currently active pipeline.",{"type":21,"tag":294,"props":295,"children":297},"validity-group",{"name":296},"Valid Usage",[298],{"type":21,"tag":299,"props":300,"children":302},"validity-field",{"name":301},"VUID-vkCmdSetLogicOpEXT-None-09422",[303],{"type":21,"tag":22,"props":304,"children":305},{},[306,308,313],{"type":26,"value":307},"At least one of the following ",{"type":21,"tag":309,"props":310,"children":312},"normative",{"type":311},"must",[],{"type":26,"value":314}," be true:",{"type":21,"tag":294,"props":316,"children":318},{"name":317},"Valid Usage (Implicit)",[319,346,371,395,424],{"type":21,"tag":299,"props":320,"children":322},{"name":321},"VUID-vkCmdSetLogicOpEXT-commandBuffer-parameter",[323],{"type":21,"tag":22,"props":324,"children":325},{},[326,331,333,336,338,344],{"type":21,"tag":51,"props":327,"children":329},{"className":328},[],[330],{"type":26,"value":92},{"type":26,"value":332}," ",{"type":21,"tag":309,"props":334,"children":335},{"type":311},[],{"type":26,"value":337}," be a valid ",{"type":21,"tag":29,"props":339,"children":341},{"href":340},"/man/VkCommandBuffer",[342],{"type":26,"value":343},"VkCommandBuffer",{"type":26,"value":345}," handle",{"type":21,"tag":299,"props":347,"children":349},{"name":348},"VUID-vkCmdSetLogicOpEXT-logicOp-parameter",[350],{"type":21,"tag":22,"props":351,"children":352},{},[353,358,359,362,363,369],{"type":21,"tag":51,"props":354,"children":356},{"className":355},[],[357],{"type":26,"value":111},{"type":26,"value":332},{"type":21,"tag":309,"props":360,"children":361},{"type":311},[],{"type":26,"value":337},{"type":21,"tag":29,"props":364,"children":366},{"href":365},"/man/VkLogicOp",[367],{"type":26,"value":368},"VkLogicOp",{"type":26,"value":370}," value",{"type":21,"tag":299,"props":372,"children":374},{"name":373},"VUID-vkCmdSetLogicOpEXT-commandBuffer-recording",[375],{"type":21,"tag":22,"props":376,"children":377},{},[378,383,384,387,389],{"type":21,"tag":51,"props":379,"children":381},{"className":380},[],[382],{"type":26,"value":92},{"type":26,"value":332},{"type":21,"tag":309,"props":385,"children":386},{"type":311},[],{"type":26,"value":388}," be in the ",{"type":21,"tag":29,"props":390,"children":392},{"href":391},"/chapters/commandbuffers#commandbuffers-lifecycle",[393],{"type":26,"value":394},"recording state",{"type":21,"tag":299,"props":396,"children":398},{"name":397},"VUID-vkCmdSetLogicOpEXT-commandBuffer-cmdpool",[399],{"type":21,"tag":22,"props":400,"children":401},{},[402,404,410,412,417,419,422],{"type":26,"value":403},"The ",{"type":21,"tag":51,"props":405,"children":407},{"className":406},[],[408],{"type":26,"value":409},"VkCommandPool",{"type":26,"value":411}," that ",{"type":21,"tag":51,"props":413,"children":415},{"className":414},[],[416],{"type":26,"value":92},{"type":26,"value":418}," was allocated from ",{"type":21,"tag":309,"props":420,"children":421},{"type":311},[],{"type":26,"value":423}," support graphics operations",{"type":21,"tag":299,"props":425,"children":427},{"name":426},"VUID-vkCmdSetLogicOpEXT-videocoding",[428],{"type":21,"tag":22,"props":429,"children":430},{},[431,433,436],{"type":26,"value":432},"This command ",{"type":21,"tag":309,"props":434,"children":435},{"type":311},[],{"type":26,"value":437}," only be called outside of a video coding scope",{"type":21,"tag":439,"props":440,"children":442},"validity-box",{"name":441},"Host Synchronization",[443],{"type":21,"tag":219,"props":444,"children":445},{},[446,462],{"type":21,"tag":223,"props":447,"children":448},{},[449,451,456,457,460],{"type":26,"value":450},"Host access to ",{"type":21,"tag":51,"props":452,"children":454},{"className":453},[],[455],{"type":26,"value":92},{"type":26,"value":332},{"type":21,"tag":309,"props":458,"children":459},{"type":311},[],{"type":26,"value":461}," be externally synchronized",{"type":21,"tag":223,"props":463,"children":464},{},[465,467,472,473,478,479,482],{"type":26,"value":466},"Host access to the ",{"type":21,"tag":51,"props":468,"children":470},{"className":469},[],[471],{"type":26,"value":409},{"type":26,"value":411},{"type":21,"tag":51,"props":474,"children":476},{"className":475},[],[477],{"type":26,"value":92},{"type":26,"value":418},{"type":21,"tag":309,"props":480,"children":481},{"type":311},[],{"type":26,"value":483}," be externally synchronized\n::",{"type":21,"tag":485,"props":486,"children":487},"style",{},[488],{"type":26,"value":489},"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":491},[],"markdown",1725732609319]