anv_image_view_init(struct anv_image_view *iview,
struct anv_device *device,
const VkImageViewCreateInfo* pCreateInfo,
- struct anv_cmd_buffer *cmd_buffer)
+ struct anv_cmd_buffer *cmd_buffer,
+ uint32_t offset)
{
ANV_FROM_HANDLE(anv_image, image, pCreateInfo->image);
const VkImageSubresourceRange *range = &pCreateInfo->subresourceRange;
iview->image = image;
iview->bo = image->bo;
- iview->offset = image->offset + surface->offset;
+ iview->offset = image->offset + surface->offset + offset;
iview->aspect_mask = pCreateInfo->subresourceRange.aspectMask;
iview->vk_format = pCreateInfo->format;
if (view == NULL)
return vk_error(VK_ERROR_OUT_OF_HOST_MEMORY);
- anv_image_view_init(view, device, pCreateInfo, NULL);
+ anv_image_view_init(view, device, pCreateInfo, NULL, 0);
*pView = anv_image_view_to_handle(view);
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
struct anv_image_view dest_iview;
anv_image_view_init(&dest_iview, cmd_buffer->device,
.layerCount = 1,
},
},
- cmd_buffer);
+ cmd_buffer, 0);
meta_emit_blit(cmd_buffer,
anv_image_from_handle(src_image),
.layerCount = pRegions[r].dstSubresource.layerCount,
},
},
- cmd_buffer);
+ cmd_buffer, 0);
const VkOffset3D dest_offset = {
.x = pRegions[r].dstOffset.x,
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
meta_emit_blit(cmd_buffer,
src_image, &src_iview,
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
const VkOffset3D dest_offset = {
.x = pRegions[r].dstOffsets[0].x,
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
meta_emit_blit(cmd_buffer,
src_image, &src_iview,
.layerCount = 1,
},
},
- cmd_buffer);
+ cmd_buffer, 0);
uint32_t img_x = 0;
uint32_t img_y = 0;
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, img_o);
const VkExtent3D img_extent_el = meta_region_extent_el(dest_image->vk_format,
&pRegions[r].imageExtent);
.layerCount = pRegions[r].imageSubresource.layerCount,
},
},
- cmd_buffer);
+ cmd_buffer, 0);
struct anv_image *dest_image =
make_image_for_buffer(vk_device, destBuffer, buffer_format,
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
meta_emit_blit(cmd_buffer,
anv_image_from_handle(srcImage),
.layerCount = 1
},
},
- cmd_buffer);
+ cmd_buffer, 0);
VkFramebuffer fb;
anv_CreateFramebuffer(device_h,
void anv_image_view_init(struct anv_image_view *view,
struct anv_device *device,
const VkImageViewCreateInfo* pCreateInfo,
- struct anv_cmd_buffer *cmd_buffer);
+ struct anv_cmd_buffer *cmd_buffer,
+ uint32_t offset);
void
anv_fill_image_surface_state(struct anv_device *device, struct anv_state state,