Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Graphics/GraphicsEngineVulkan/include/TextureVkImpl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,11 @@ class TextureVkImpl final : public TextureBase<EngineVkImplTraits>
return StagingDataCPUAddress;
}

VulkanUtilities::MemoryAllocation& GetMemoryAllocation()
{
return m_MemoryAllocation;
}
Comment on lines +92 to +95
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be const


void InvalidateStagingRange(VkDeviceSize Offset, VkDeviceSize Size);

// For non-compressed color format buffer, the offset must be a multiple of the format's texel block size.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@

namespace Diligent
{
struct RenderDeviceVkImpl;
VkImageCreateInfo TextureDescToVkImageCreateInfo(const TextureDesc& Desc, const RenderDeviceVkImpl* pRenderDeviceVk) noexcept;

VkFormat TexFormatToVkFormat(TEXTURE_FORMAT TexFmt);
TEXTURE_FORMAT VkFormatToTexFormat(VkFormat VkFmt);
Expand Down
6 changes: 3 additions & 3 deletions Graphics/GraphicsEngineVulkan/src/TextureVkImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@
namespace Diligent
{

namespace
{

VkImageCreateInfo TextureDescToVkImageCreateInfo(const TextureDesc& Desc, const RenderDeviceVkImpl* pRenderDeviceVk) noexcept
{
const bool IsMemoryless = (Desc.MiscFlags & MISC_TEXTURE_FLAG_MEMORYLESS) != 0;
Expand Down Expand Up @@ -147,6 +144,9 @@ VkImageCreateInfo TextureDescToVkImageCreateInfo(const TextureDesc& Desc, const
return ImageCI;
}

namespace
{

VkImageLayout VkImageLayoutFromUsage(VkImageUsageFlags Usage)
{
if ((Usage & (VK_IMAGE_USAGE_SAMPLED_BIT | VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT)) != 0)
Expand Down
Loading