mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-21 10:49:14 +00:00
Various cleanups for updated indexFormat handling
Addresses post-merge comments left by cwallez@ on https://dawn-review.googlesource.com/c/dawn/+/27182 BUG=dawn:502 Change-Id: I9bce09da9bb46e92a4c613df2279bdefdd06d747 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27761 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Brandon Jones <bajones@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
be53792880
commit
ccda6a0009
@@ -577,9 +577,16 @@ TEST_F(RenderPipelineValidationTest, StripIndexFormatRequired) {
|
||||
descriptor.primitiveTopology = primitiveTopology;
|
||||
descriptor.cVertexState.indexFormat = indexFormat;
|
||||
|
||||
// Succeeds even when the index format is undefined because the
|
||||
// primitive topology isn't a strip type.
|
||||
device.CreateRenderPipeline(&descriptor);
|
||||
if (indexFormat == wgpu::IndexFormat::Undefined) {
|
||||
// Succeeds even when the index format is undefined because the
|
||||
// primitive topology isn't a strip type.
|
||||
device.CreateRenderPipeline(&descriptor);
|
||||
} else {
|
||||
// TODO(crbug.com/dawn/502): Once setIndexBuffer requires an
|
||||
// indexFormat. this should fail. For now it succeeds to allow
|
||||
// backwards compatibility during the deprecation period.
|
||||
device.CreateRenderPipeline(&descriptor);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user