Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //helper functions will be provided in the bottom of the page
- //Create VKImage with the VK_FORMAT_R32_SFLOAT format for the color attachment
- create_image(swapChainExtent.width, swapChainExtent.height, 1, VK_SAMPLE_COUNT_1_BIT,VK_FORMAT_R32_SFLOAT, VK_IMAGE_TILING_OPTIMAL,
- VK_IMAGE_USAGE_TRANSIENT_ATTACHMENT_BIT | VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT, VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT,
- object_picking_colorImage, object_picking_colorImageMemory);
- //Create VKImageView with the VK_FORMAT_R32_SFLOAT format for the color attachment
- object_picking_colorImageView = create_image_view(object_picking_colorImage, VK_FORMAT_R32_SFLOAT, VK_IMAGE_ASPECT_COLOR_BIT, 1);
- //Create VKImage with the VK_FORMAT_R32_SFLOAT format for the depth attachment
- create_image(swapChainExtent.width, swapChainExtent.height, 1, VK_SAMPLE_COUNT_1_BIT, depthFormat, VK_IMAGE_TILING_OPTIMAL,
- VK_IMAGE_USAGE_DEPTH_STENCIL_ATTACHMENT_BIT, VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT, object_picking_depthImage,
- object_picking_depthImageMemory);
- //Create VKImageView with the VK_FORMAT_R32_SFLOAT format for the depth attachment
- object_picking_depthImageView = create_image_view(object_picking_depthImage, depthFormat, VK_IMAGE_ASPECT_DEPTH_BIT, 1);
Add Comment
Please, Sign In to add comment