mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-14 07:36:15 +00:00
API evolution GPUExtent3D.depth -> depthOrArrayLayers (Step 2)
Still leave deprecated `depth` functional as there are some references in other clients. Using `depth` and `depthOrArrayLayers` at the same time is invalid. Add DeprecatedAPITests. Bug: chromium:1176969 Change-Id: Ia06645e4f3c17588323dd36b11f9f3988b2e3aba Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/44640 Commit-Queue: Shrek Shao <shrekshao@google.com> Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
a9b211d202
commit
b00de7f8e8
@@ -40,7 +40,8 @@ namespace utils {
|
||||
TextureDataCopyLayout layout;
|
||||
|
||||
layout.mipSize = {textureSizeAtLevel0.width >> mipmapLevel,
|
||||
textureSizeAtLevel0.height >> mipmapLevel, textureSizeAtLevel0.depth};
|
||||
textureSizeAtLevel0.height >> mipmapLevel,
|
||||
textureSizeAtLevel0.depthOrArrayLayers};
|
||||
|
||||
layout.bytesPerRow = GetMinimumBytesPerRow(format, layout.mipSize.width);
|
||||
|
||||
@@ -83,7 +84,7 @@ namespace utils {
|
||||
ASSERT(copyExtent.height % blockHeight == 0);
|
||||
uint32_t heightInBlocks = copyExtent.height / blockHeight;
|
||||
return RequiredBytesInCopy(bytesPerRow, rowsPerImage, widthInBlocks, heightInBlocks,
|
||||
copyExtent.depth, blockSize);
|
||||
copyExtent.depthOrArrayLayers, blockSize);
|
||||
}
|
||||
|
||||
uint64_t RequiredBytesInCopy(uint64_t bytesPerRow,
|
||||
|
||||
@@ -258,7 +258,7 @@ namespace utils {
|
||||
descriptor.dimension = wgpu::TextureDimension::e2D;
|
||||
descriptor.size.width = width;
|
||||
descriptor.size.height = height;
|
||||
descriptor.size.depth = 1;
|
||||
descriptor.size.depthOrArrayLayers = 1;
|
||||
descriptor.sampleCount = 1;
|
||||
descriptor.format = BasicRenderPass::kDefaultColorFormat;
|
||||
descriptor.mipLevelCount = 1;
|
||||
|
||||
Reference in New Issue
Block a user