Lines Matching defs:attachment

1699     /* Walk attachment list and outputs together */
1708 "FS writes to output location %d with no matching attachment", it_a->first.first)) {
2067 // Verify attachment reference compatibility according to spec
2077 if (VK_ATTACHMENT_UNUSED == pSecondary[index].attachment)
2080 if (VK_ATTACHMENT_UNUSED == pPrimary[index].attachment)
2083 if ((pPrimaryAttachments[pPrimary[index].attachment].format ==
2084 pSecondaryAttachments[pSecondary[index].attachment].format) &&
2085 (pPrimaryAttachments[pPrimary[index].attachment].samples ==
2086 pSecondaryAttachments[pSecondary[index].attachment].samples))
2127 // For each subpass, verify that corresponding color, input, resolve & depth/stencil attachment references are compatible
2705 "Render pass subpass %u mismatch with blending state defined and blend state attachment "
2706 "count %u while subpass color attachment count %u in Pipeline (0x%" PRIxLEAST64 ")! These "
2715 if (subpass_desc->pColorAttachments[i].attachment == VK_ATTACHMENT_UNUSED)
2718 samples = render_pass_info->pAttachments[subpass_desc->pColorAttachments[i].attachment].samples;
2727 (subpass_desc->pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED)) {
2729 render_pass_info->pAttachments[subpass_desc->pDepthStencilAttachment->attachment].samples;
5587 // If any attachment used by this pipeline has blendEnable, set top-level blendEnable
7265 // Warn if this is issued prior to Draw Cmd and clearing the entire attachment
7282 // Validate that attachment is in reference list of active subpass
7288 const VkClearAttachment *attachment = &pAttachments[attachment_idx];
7289 if (attachment->aspectMask & VK_IMAGE_ASPECT_COLOR_BIT) {
7292 if (attachment->colorAttachment == pSD->pColorAttachments[i].attachment) {
7301 "vkCmdClearAttachments() attachment index %d not found in attachment reference array of active subpass %d",
7302 attachment->colorAttachment, pCB->activeSubpass);
7304 } else if (attachment->aspectMask & (VK_IMAGE_ASPECT_DEPTH_BIT | VK_IMAGE_ASPECT_STENCIL_BIT)) {
7306 (pSD->pDepthStencilAttachment->attachment ==
7312 "vkCmdClearAttachments() attachment index %d does not match depthStencilAttachment.attachment (%d) found "
7314 attachment->colorAttachment,
7315 (pSD->pDepthStencilAttachment) ? pSD->pDepthStencilAttachment->attachment : VK_ATTACHMENT_UNUSED,
8232 // Loop through all subpasses that share the same attachment and make sure a dependency exists
8262 const uint32_t attachment, const std::vector<DAGNode> &subpass_to_node, int depth, bool &skip_call) {
8264 // If this node writes to the attachment return true as next nodes need to preserve the attachment.
8267 if (attachment == subpass.pColorAttachments[j].attachment)
8270 if (subpass.pDepthStencilAttachment && subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED) {
8271 if (attachment == subpass.pDepthStencilAttachment->attachment)
8275 // Loop through previous nodes and see if any of them write to the attachment.
8277 result |= CheckPreserved(my_data, pCreateInfo, elem, attachment, subpass_to_node, depth + 1, skip_call);
8279 // If the attachment was written to by a previous node than this node needs to preserve it.
8284 if (subpass.pPreserveAttachments[j] == attachment) {
8293 "Attachment %d is used by a later subpass and must be preserved in subpass %d.", attachment, index);
8353 uint32_t attachment = i;
8355 if (!(pCreateInfo->pAttachments[attachment].flags & VK_ATTACHMENT_DESCRIPTION_MAY_ALIAS_BIT)) {
8358 DRAWSTATE_INVALID_RENDERPASS, "DS", "Attachment %d aliases attachment %d but doesn't "
8360 attachment, other_attachment);
8365 DRAWSTATE_INVALID_RENDERPASS, "DS", "Attachment %d aliases attachment %d but doesn't "
8367 other_attachment, attachment);
8371 // Find for each attachment the subpasses that use them.
8377 uint32_t attachment = subpass.pInputAttachments[j].attachment;
8378 input_attachment_to_subpass[attachment].push_back(i);
8379 for (auto overlapping_attachment : overlapping_attachments[attachment]) {
8384 uint32_t attachment = subpass.pColorAttachments[j].attachment;
8385 output_attachment_to_subpass[attachment].push_back(i);
8386 for (auto overlapping_attachment : overlapping_attachments[attachment]) {
8389 attachmentIndices.insert(attachment);
8391 if (subpass.pDepthStencilAttachment && subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED) {
8392 uint32_t attachment = subpass.pDepthStencilAttachment->attachment;
8393 output_attachment_to_subpass[attachment].push_back(i);
8394 for (auto overlapping_attachment : overlapping_attachments[attachment]) {
8398 if (attachmentIndices.count(attachment)) {
8402 "Cannot use same attachment (%u) as both color and depth output in same subpass (%u).",
8403 attachment, i);
8410 // If the attachment is an input then all subpasses that output must have a dependency relationship
8412 const uint32_t &attachment = subpass.pInputAttachments[j].attachment;
8413 CheckDependencyExists(my_data, i, output_attachment_to_subpass[attachment], subpass_to_node, skip_call);
8415 // If the attachment is an output then all subpasses that use the attachment must have a dependency relationship
8417 const uint32_t &attachment = subpass.pColorAttachments[j].attachment;
8418 CheckDependencyExists(my_data, i, output_attachment_to_subpass[attachment], subpass_to_node, skip_call);
8419 CheckDependencyExists(my_data, i, input_attachment_to_subpass[attachment], subpass_to_node, skip_call);
8421 if (subpass.pDepthStencilAttachment && subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED) {
8422 const uint32_t &attachment = subpass.pDepthStencilAttachment->attachment;
8423 CheckDependencyExists(my_data, i, output_attachment_to_subpass[attachment], subpass_to_node, skip_call);
8424 CheckDependencyExists(my_data, i, input_attachment_to_subpass[attachment], subpass_to_node, skip_call);
8427 // Loop through implicit dependencies, if this pass reads make sure the attachment is preserved for all passes after it was
8432 CheckPreserved(my_data, pCreateInfo, i, subpass.pInputAttachments[j].attachment, subpass_to_node, 0, skip_call);
8441 const uint32_t attachment,
8451 "Cannot clear attachment %d with invalid first layout %s.", attachment, string_VkImageLayout(first_layout));
8469 "Layout for input attachment is GENERAL but should be READ_ONLY_OPTIMAL.");
8473 "Layout for input attachment is %s but can only be READ_ONLY_OPTIMAL or GENERAL.",
8477 auto attach_index = subpass.pInputAttachments[j].attachment;
8487 "Layout for color attachment is GENERAL but should be COLOR_ATTACHMENT_OPTIMAL.");
8491 "Layout for color attachment is %s but can only be COLOR_ATTACHMENT_OPTIMAL or GENERAL.",
8495 auto attach_index = subpass.pColorAttachments[j].attachment;
8499 if ((subpass.pDepthStencilAttachment != NULL) && (subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED)) {
8505 "Layout for depth attachment is GENERAL but should be DEPTH_STENCIL_ATTACHMENT_OPTIMAL.");
8510 "Layout for depth attachment is %s but can only be DEPTH_STENCIL_ATTACHMENT_OPTIMAL or GENERAL.",
8514 auto attach_index = subpass.pDepthStencilAttachment->attachment;
8647 subpass->pPreserveAttachments = &attachments->attachment;
8667 pass_info.attachment = i;
8682 uint32_t attachment = subpass.pPreserveAttachments[j];
8683 if (attachment >= pCreateInfo->attachmentCount) {
8686 "Preserve attachment %d cannot be greater than the total number of attachments %d.",
8687 attachment, pCreateInfo->attachmentCount);
8691 uint32_t attachment;
8693 attachment = subpass.pResolveAttachments[j].attachment;
8694 if (attachment >= pCreateInfo->attachmentCount && attachment != VK_ATTACHMENT_UNUSED) {
8697 "Color attachment %d cannot be greater than the total number of attachments %d.",
8698 attachment, pCreateInfo->attachmentCount);
8702 attachment = subpass.pColorAttachments[j].attachment;
8703 if (attachment >= pCreateInfo->attachmentCount) {
8706 "Color attachment %d cannot be greater than the total number of attachments %d.",
8707 attachment, pCreateInfo->attachmentCount);
8710 if (attachment_first_read.count(attachment))
8712 attachment_first_read.insert(std::make_pair(attachment, false));
8713 attachment_first_layout.insert(std::make_pair(attachment, subpass.pColorAttachments[j].layout));
8715 if (subpass.pDepthStencilAttachment && subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED) {
8716 uint32_t attachment = subpass.pDepthStencilAttachment->attachment;
8717 if (attachment >= pCreateInfo->attachmentCount) {
8720 "Depth stencil attachment %d cannot be greater than the total number of attachments %d.",
8721 attachment, pCreateInfo->attachmentCount);
8724 if (attachment_first_read.count(attachment))
8726 attachment_first_read.insert(std::make_pair(attachment, false));
8727 attachment_first_layout.insert(std::make_pair(attachment, subpass.pDepthStencilAttachment->layout));
8730 uint32_t attachment = subpass.pInputAttachments[j].attachment;
8731 if (attachment >= pCreateInfo->attachmentCount) {
8734 "Input attachment %d cannot be greater than the total number of attachments %d.",
8735 attachment, pCreateInfo->attachmentCount);
8738 if (attachment_first_read.count(attachment))
8740 attachment_first_read.insert(std::make_pair(attachment, true));
8741 attachment_first_layout.insert(std::make_pair(attachment, subpass.pInputAttachments[j].layout));
8813 DRAWSTATE_INVALID_RENDERPASS, "DS", "You cannot start a render pass using attachment %i "
8815 "initial layout is %s and the layout of the attachment at the "
8838 const VkImageView &image_view = framebufferInfo.pAttachments[subpass.pInputAttachments[j].attachment];
8842 const VkImageView &image_view = framebufferInfo.pAttachments[subpass.pColorAttachments[j].attachment];
8845 if ((subpass.pDepthStencilAttachment != NULL) && (subpass.pDepthStencilAttachment->attachment != VK_ATTACHMENT_UNUSED)) {
8846 const VkImageView &image_view = framebufferInfo.pAttachments[subpass.pDepthStencilAttachment->attachment];
8928 if (renderPass->attachment_first_read[renderPass->attachments[i].attachment]) {
9085 primary_input_attach = primary_desc.pInputAttachments[i].attachment;
9088 secondary_input_attach = secondary_desc.pInputAttachments[i].attachment;
9097 primary_color_attach = primary_desc.pColorAttachments[i].attachment;
9100 secondary_color_attach = secondary_desc.pColorAttachments[i].attachment;
9106 primary_resolve_attach = primary_desc.pResolveAttachments[i].attachment;
9109 secondary_resolve_attach = secondary_desc.pResolveAttachments[i].attachment;
9116 primary_depthstencil_attach = primary_desc.pDepthStencilAttachment[0].attachment;
9119 secondary_depthstencil_attach = secondary_desc.pDepthStencilAttachment[0].attachment;