mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-01 16:24:12 +01:00
[dxvk] Add slice alignment to copyImageToBuffer
This commit is contained in:
parent
4840cdaf8c
commit
ba4938e201
@ -4052,7 +4052,7 @@ namespace dxvk {
|
||||
cPackedFormat = packedFormat
|
||||
] (DxvkContext* ctx) {
|
||||
if (cSubresources.aspectMask != (VK_IMAGE_ASPECT_DEPTH_BIT | VK_IMAGE_ASPECT_STENCIL_BIT)) {
|
||||
ctx->copyImageToBuffer(cImageBuffer, 0, 0,
|
||||
ctx->copyImageToBuffer(cImageBuffer, 0, 0, 0,
|
||||
cImage, cSubresources, VkOffset3D { 0, 0, 0 },
|
||||
cLevelExtent);
|
||||
} else {
|
||||
|
@ -866,7 +866,7 @@ namespace dxvk {
|
||||
cLevelExtent = srcExtent,
|
||||
cDstExtent = dstExtent
|
||||
] (DxvkContext* ctx) {
|
||||
ctx->copyImageToBuffer(cBuffer, 0, 4,
|
||||
ctx->copyImageToBuffer(cBuffer, 0, 4, 0,
|
||||
cImage, cSubresources, VkOffset3D { 0, 0, 0 },
|
||||
cLevelExtent);
|
||||
});
|
||||
@ -4166,7 +4166,7 @@ namespace dxvk {
|
||||
cPackedFormat = packedFormat
|
||||
] (DxvkContext* ctx) {
|
||||
if (cSubresources.aspectMask != (VK_IMAGE_ASPECT_DEPTH_BIT | VK_IMAGE_ASPECT_STENCIL_BIT)) {
|
||||
ctx->copyImageToBuffer(cImageBuffer, 0, 0,
|
||||
ctx->copyImageToBuffer(cImageBuffer, 0, 0, 0,
|
||||
cImage, cSubresources, VkOffset3D { 0, 0, 0 },
|
||||
cLevelExtent);
|
||||
} else {
|
||||
|
@ -456,7 +456,7 @@ namespace dxvk {
|
||||
cSubresources = srcSubresourceLayers,
|
||||
cLevelExtent = srcExtent
|
||||
] (DxvkContext* ctx) {
|
||||
ctx->copyImageToBuffer(cBuffer, 0, 0,
|
||||
ctx->copyImageToBuffer(cBuffer, 0, 0, 0,
|
||||
cImage, cSubresources, VkOffset3D { 0, 0, 0 },
|
||||
cLevelExtent);
|
||||
});
|
||||
|
@ -894,6 +894,7 @@ namespace dxvk {
|
||||
const Rc<DxvkBuffer>& dstBuffer,
|
||||
VkDeviceSize dstOffset,
|
||||
VkDeviceSize rowAlignment,
|
||||
VkDeviceSize sliceAlignment,
|
||||
const Rc<DxvkImage>& srcImage,
|
||||
VkImageSubresourceLayers srcSubresource,
|
||||
VkOffset3D srcOffset,
|
||||
@ -928,7 +929,7 @@ namespace dxvk {
|
||||
m_execAcquires.recordCommands(m_cmd);
|
||||
|
||||
this->copyImageBufferData<false>(DxvkCmdBuffer::ExecBuffer, srcImage, srcSubresource,
|
||||
srcOffset, srcExtent, srcImageLayoutTransfer, dstSlice, rowAlignment, 0);
|
||||
srcOffset, srcExtent, srcImageLayoutTransfer, dstSlice, rowAlignment, sliceAlignment);
|
||||
|
||||
m_execBarriers.accessImage(
|
||||
srcImage, srcSubresourceRange,
|
||||
|
@ -403,6 +403,8 @@ namespace dxvk {
|
||||
* \param [in] dstBuffer Destination buffer
|
||||
* \param [in] dstOffset Destination offset, in bytes
|
||||
* \param [in] dstExtent Destination data extent
|
||||
* \param [in] rowAlignment Row alignment, in bytes
|
||||
* \param [in] sliceAlignment Slice alignment, in bytes
|
||||
* \param [in] srcImage Source image
|
||||
* \param [in] srcSubresource Source subresource
|
||||
* \param [in] srcOffset Source area offset
|
||||
@ -412,6 +414,7 @@ namespace dxvk {
|
||||
const Rc<DxvkBuffer>& dstBuffer,
|
||||
VkDeviceSize dstOffset,
|
||||
VkDeviceSize rowAlignment,
|
||||
VkDeviceSize sliceAlignment,
|
||||
const Rc<DxvkImage>& srcImage,
|
||||
VkImageSubresourceLayers srcSubresource,
|
||||
VkOffset3D srcOffset,
|
||||
|
Loading…
Reference in New Issue
Block a user