Refactor TransitionUsage to use abstract TransitionUsageImpl

This commit is contained in:
Austin Eng
2017-06-12 18:31:10 -04:00
committed by Austin Eng
parent 39c901d3dc
commit 459537491b
15 changed files with 71 additions and 12 deletions

View File

@@ -156,6 +156,9 @@ namespace d3d12 {
// TODO(cwallez@chromium.org): Implement Map Read for the null backend
}
void Buffer::TransitionUsageImpl(nxt::BufferUsageBit currentUsage, nxt::BufferUsageBit targetUsage) {
}
// BufferView
BufferView::BufferView(Device* device, BufferViewBuilder* builder)
@@ -198,6 +201,9 @@ namespace d3d12 {
: TextureBase(builder), device(device) {
}
void Texture::TransitionUsageImpl(nxt::TextureUsageBit currentUsage, nxt::TextureUsageBit targetUsage) {
}
// TextureView
TextureView::TextureView(Device* device, TextureViewBuilder* builder)

View File

@@ -145,6 +145,7 @@ namespace d3d12 {
void SetSubDataImpl(uint32_t start, uint32_t count, const uint32_t* data) override;
void MapReadAsyncImpl(uint32_t serial, uint32_t start, uint32_t count) override;
void UnmapImpl() override;
void TransitionUsageImpl(nxt::BufferUsageBit currentUsage, nxt::BufferUsageBit targetUsage) override;
Device* device;
};
@@ -202,6 +203,8 @@ namespace d3d12 {
Texture(Device* device, TextureBuilder* builder);
private:
void TransitionUsageImpl(nxt::TextureUsageBit currentUsage, nxt::TextureUsageBit targetUsage) override;
Device* device;
};