mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-21 18:59:21 +00:00
Remove Bit from TextureUsageBit and BufferUsageBit
This is to match the naming convention of WebGPU's WebIDL and webgpu.h BUG=dawn:22 Change-Id: Ia91c5a018403e6a72eb0311b5f1a072d102282a2 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/10461 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
e25a3aede0
commit
9e9e29f7a6
@@ -81,7 +81,7 @@ namespace dawn_native {
|
||||
}
|
||||
|
||||
void SwapChainBase::Configure(dawn::TextureFormat format,
|
||||
dawn::TextureUsageBit allowedUsage,
|
||||
dawn::TextureUsage allowedUsage,
|
||||
uint32_t width,
|
||||
uint32_t height) {
|
||||
if (GetDevice()->ConsumedError(ValidateConfigure(format, allowedUsage, width, height))) {
|
||||
@@ -89,14 +89,14 @@ namespace dawn_native {
|
||||
}
|
||||
ASSERT(!IsError());
|
||||
|
||||
allowedUsage |= dawn::TextureUsageBit::Present;
|
||||
allowedUsage |= dawn::TextureUsage::Present;
|
||||
|
||||
mFormat = format;
|
||||
mAllowedUsage = allowedUsage;
|
||||
mWidth = width;
|
||||
mHeight = height;
|
||||
mImplementation.Configure(mImplementation.userData, static_cast<DawnTextureFormat>(format),
|
||||
static_cast<DawnTextureUsageBit>(allowedUsage), width, height);
|
||||
static_cast<DawnTextureUsage>(allowedUsage), width, height);
|
||||
}
|
||||
|
||||
TextureBase* SwapChainBase::GetNextTexture() {
|
||||
@@ -138,12 +138,12 @@ namespace dawn_native {
|
||||
}
|
||||
|
||||
MaybeError SwapChainBase::ValidateConfigure(dawn::TextureFormat format,
|
||||
dawn::TextureUsageBit allowedUsage,
|
||||
dawn::TextureUsage allowedUsage,
|
||||
uint32_t width,
|
||||
uint32_t height) const {
|
||||
DAWN_TRY(GetDevice()->ValidateObject(this));
|
||||
|
||||
DAWN_TRY(ValidateTextureUsageBit(allowedUsage));
|
||||
DAWN_TRY(ValidateTextureUsage(allowedUsage));
|
||||
DAWN_TRY(ValidateTextureFormat(format));
|
||||
|
||||
if (width == 0 || height == 0) {
|
||||
|
||||
Reference in New Issue
Block a user