Lines Matching refs:vk
79 uint32_t width = image->vk.extent.width;
80 uint32_t height = image->vk.extent.height;
81 uint32_t depth = image->vk.extent.depth;
97 uint32_t block_width = vk_format_get_blockwidth(image->vk.format);
98 uint32_t block_height = vk_format_get_blockheight(image->vk.format);
100 assert(image->vk.samples == VK_SAMPLE_COUNT_1_BIT ||
101 image->vk.samples == VK_SAMPLE_COUNT_4_BIT);
102 bool msaa = image->vk.samples != VK_SAMPLE_COUNT_1_BIT;
106 assert(image->vk.array_layers > 0);
108 assert(image->vk.mip_levels >= 1);
111 for (int32_t i = image->vk.mip_levels - 1; i >= 0; i--) {
138 if (image->vk.image_type == VK_IMAGE_TYPE_1D)
218 for (int i = 0; i < image->vk.mip_levels; i++)
226 if (image->vk.image_type != VK_IMAGE_TYPE_3D) {
229 image->size += image->cube_map_stride * (image->vk.array_layers - 1);
240 if (image->vk.image_type == VK_IMAGE_TYPE_3D)
254 image = vk_image_create(&device->vk, pCreateInfo, pAllocator, sizeof(*image));
296 image->vk.wsi_legacy_scanout) {
308 image->cpp = vk_format_get_blocksize(image->vk.format);
313 image->vk.tiling = tiling;
314 image->vk.drm_format_mod = modifier;
320 image->vk.create_flags |= VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT;
351 local_create_info.tiling = swapchain_image->vk.tiling;
356 .pDrmFormatModifiers = &swapchain_image->vk.drm_format_mod,
359 if (swapchain_image->vk.drm_format_mod != DRM_FORMAT_MOD_INVALID)
362 assert(swapchain_image->vk.image_type == local_create_info.imageType);
363 assert(swapchain_image->vk.format == local_create_info.format);
364 assert(swapchain_image->vk.extent.width == local_create_info.extent.width);
365 assert(swapchain_image->vk.extent.height == local_create_info.extent.height);
366 assert(swapchain_image->vk.extent.depth == local_create_info.extent.depth);
367 assert(swapchain_image->vk.array_layers == local_create_info.arrayLayers);
368 assert(swapchain_image->vk.samples == local_create_info.samples);
369 assert(swapchain_image->vk.tiling == local_create_info.tiling);
370 assert((swapchain_image->vk.usage & local_create_info.usage) ==
409 if (image->vk.image_type != VK_IMAGE_TYPE_3D) {
419 layout->size = slice->size * image->vk.extent.depth;
439 vk_image_destroy(&device->vk, pAllocator, &image->vk);
487 iview = vk_image_view_create(&device->vk, pCreateInfo, pAllocator,
494 iview->offset = v3dv_layer_offset(image, iview->vk.base_mip_level,
495 iview->vk.base_array_layer);
514 /* FIXME: we are doing this vk to pipe swizzle mapping just to call
516 * better to reimplement the latter using vk component
519 vk_component_mapping_to_pipe_swizzle(iview->vk.swizzle.r);
521 vk_component_mapping_to_pipe_swizzle(iview->vk.swizzle.g);
523 vk_component_mapping_to_pipe_swizzle(iview->vk.swizzle.b);
525 vk_component_mapping_to_pipe_swizzle(iview->vk.swizzle.a);
528 iview->vk.format = format;
532 if (vk_format_is_depth_or_stencil(iview->vk.format)) {
534 v3dv_X(device, get_internal_depth_type)(iview->vk.format);
563 vk_image_view_destroy(&device->vk, pAllocator, &image_view->vk);
578 vk_object_zalloc(&device->vk, pAllocator, sizeof(*view),
622 vk_object_free(&device->vk, pAllocator, buffer_view);