mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-20 18:29:23 +00:00
Add validation code for texture subresource usage tracking
This patch also add validation tests for texture subresource tracking for render pass. Resource usage tracking for compute is per each dispatch() call, I will add it in next patch. BUG=dawn:157 Change-Id: I6c4b932e317d66521fa428311e727876d0adf4ea Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/17661 Commit-Queue: Yunchao He <yunchao.he@intel.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
a6d7f56cf8
commit
23428ea82f
@@ -421,7 +421,7 @@ namespace dawn_native { namespace opengl {
|
||||
// Clear textures that are not output attachments. Output attachments will be
|
||||
// cleared in BeginRenderPass by setting the loadop to clear when the
|
||||
// texture subresource has not been initialized before the render pass.
|
||||
if (!(usages.textureUsages[i] & wgpu::TextureUsage::OutputAttachment)) {
|
||||
if (!(usages.textureUsages[i].usage & wgpu::TextureUsage::OutputAttachment)) {
|
||||
texture->EnsureSubresourceContentInitialized(0, texture->GetNumMipLevels(), 0,
|
||||
texture->GetArrayLayers());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user