mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 02:28:10 +02:00
radv: do not clamp framebuffer dimensions to the minimum dimension
This shouldn't be needed and this is going to be wrong with VRS attachments because dimensions are divided by the VRS texel size. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10111>
This commit is contained in:
parent
0532365759
commit
4caf19eb7d
1 changed files with 1 additions and 12 deletions
|
|
@ -7056,22 +7056,11 @@ VkResult radv_CreateFramebuffer(
|
|||
framebuffer->layers = pCreateInfo->layers;
|
||||
framebuffer->imageless = !!imageless_create_info;
|
||||
|
||||
if (imageless_create_info) {
|
||||
for (unsigned i = 0; i < imageless_create_info->attachmentImageInfoCount; ++i) {
|
||||
const VkFramebufferAttachmentImageInfo *attachment =
|
||||
imageless_create_info->pAttachmentImageInfos + i;
|
||||
framebuffer->width = MIN2(framebuffer->width, attachment->width);
|
||||
framebuffer->height = MIN2(framebuffer->height, attachment->height);
|
||||
framebuffer->layers = MIN2(framebuffer->layers, attachment->layerCount);
|
||||
}
|
||||
} else {
|
||||
if (!imageless_create_info) {
|
||||
for (uint32_t i = 0; i < pCreateInfo->attachmentCount; i++) {
|
||||
VkImageView _iview = pCreateInfo->pAttachments[i];
|
||||
struct radv_image_view *iview = radv_image_view_from_handle(_iview);
|
||||
framebuffer->attachments[i] = iview;
|
||||
framebuffer->width = MIN2(framebuffer->width, iview->extent.width);
|
||||
framebuffer->height = MIN2(framebuffer->height, iview->extent.height);
|
||||
framebuffer->layers = MIN2(framebuffer->layers, radv_surface_max_layer_count(iview));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue