d3d11: fix Queue::WriteTexture() and enable queue related tests
Bug: dawn:1705 Change-Id: I63540d46335401aeaa46efe157fdb7a191aa4637 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/128860 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org> Kokoro: Kokoro <noreply+kokoro@google.com>
This commit is contained in:
parent
85d98a91f7
commit
948ef4292f
|
@ -81,8 +81,8 @@ MaybeError Queue::WriteTextureImpl(const ImageCopyTexture& destination,
|
|||
Texture* texture = ToBackend(destination.texture);
|
||||
|
||||
return texture->Write(commandContext, subresources, destination.origin, writeSizePixel,
|
||||
static_cast<const uint8_t*>(data), dataLayout.bytesPerRow,
|
||||
dataLayout.rowsPerImage);
|
||||
static_cast<const uint8_t*>(data) + dataLayout.offset,
|
||||
dataLayout.bytesPerRow, dataLayout.rowsPerImage);
|
||||
}
|
||||
|
||||
} // namespace dawn::native::d3d11
|
||||
|
|
|
@ -30,6 +30,7 @@ TEST_P(QueueTests, GetQueueSameObject) {
|
|||
}
|
||||
|
||||
DAWN_INSTANTIATE_TEST(QueueTests,
|
||||
D3D11Backend(),
|
||||
D3D12Backend(),
|
||||
MetalBackend(),
|
||||
NullBackend(),
|
||||
|
@ -187,6 +188,7 @@ TEST_P(QueueWriteBufferTests, UnalignedDynamicUploader) {
|
|||
}
|
||||
|
||||
DAWN_INSTANTIATE_TEST(QueueWriteBufferTests,
|
||||
D3D11Backend(),
|
||||
D3D12Backend(),
|
||||
MetalBackend(),
|
||||
OpenGLBackend(),
|
||||
|
@ -639,6 +641,9 @@ TEST_P(QueueWriteTextureTests, WriteStencilAspectWithSourceOffsetUnalignedTo4) {
|
|||
// Copies to a single aspect are unsupported on OpenGL.
|
||||
DAWN_SUPPRESS_TEST_IF(IsOpenGL() || IsOpenGLES());
|
||||
|
||||
// Copies to a single aspect are unsupported on D3D11.
|
||||
DAWN_SUPPRESS_TEST_IF(IsD3D11());
|
||||
|
||||
wgpu::TextureDescriptor textureDescriptor;
|
||||
textureDescriptor.format = wgpu::TextureFormat::Depth24PlusStencil8;
|
||||
textureDescriptor.usage = wgpu::TextureUsage::CopySrc | wgpu::TextureUsage::CopyDst;
|
||||
|
@ -743,6 +748,9 @@ TEST_P(QueueWriteTextureTests, WriteStencilAspectAfterOtherQueueWriteTextureCall
|
|||
// Copies to a single aspect are unsupported on OpenGL.
|
||||
DAWN_SUPPRESS_TEST_IF(IsOpenGL() || IsOpenGLES());
|
||||
|
||||
// Copies to a single aspect are unsupported on D3D11.
|
||||
DAWN_SUPPRESS_TEST_IF(IsD3D11());
|
||||
|
||||
wgpu::TextureDescriptor textureDescriptor;
|
||||
textureDescriptor.format = wgpu::TextureFormat::Depth24PlusStencil8;
|
||||
textureDescriptor.usage = wgpu::TextureUsage::CopySrc | wgpu::TextureUsage::CopyDst;
|
||||
|
@ -771,6 +779,7 @@ TEST_P(QueueWriteTextureTests, WriteStencilAspectAfterOtherQueueWriteTextureCall
|
|||
}
|
||||
|
||||
DAWN_INSTANTIATE_TEST(QueueWriteTextureTests,
|
||||
D3D11Backend(),
|
||||
D3D12Backend(),
|
||||
D3D12Backend({"d3d12_use_temp_buffer_in_depth_stencil_texture_and_buffer_"
|
||||
"copy_with_non_zero_buffer_offset"}),
|
||||
|
|
Loading…
Reference in New Issue