| 7391 | } |
| 7392 | |
| 7393 | VmaBlockBufferImageGranularity::ValidationContext VmaBlockBufferImageGranularity::StartValidation( |
| 7394 | const VkAllocationCallbacks* pAllocationCallbacks, bool isVirutal) const |
| 7395 | { |
| 7396 | ValidationContext ctx{ pAllocationCallbacks, VMA_NULL }; |
| 7397 | if (!isVirutal && IsEnabled()) |
| 7398 | { |
| 7399 | ctx.pageAllocs = vma_new_array(pAllocationCallbacks, uint16_t, m_RegionCount); |
| 7400 | memset(ctx.pageAllocs, 0, m_RegionCount * sizeof(uint16_t)); |
| 7401 | } |
| 7402 | return ctx; |
| 7403 | } |
| 7404 | |
| 7405 | bool VmaBlockBufferImageGranularity::Validate(ValidationContext& ctx, |
| 7406 | VkDeviceSize offset, VkDeviceSize size) const |