Remove typedefs for deprecated types.
Bug: dawn:762 Change-Id: I1581d80898d4a98010bb14c5823a1a343c229664 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63383 Auto-Submit: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Brandon Jones <bajones@google.com> Reviewed-by: Brandon Jones <bajones@google.com>
This commit is contained in:
parent
d4b85fbd76
commit
363c28e5d1
14
dawn.json
14
dawn.json
|
@ -1036,10 +1036,6 @@
|
||||||
{"name": "attributes", "type": "vertex attribute", "annotation": "const*", "length": "attribute count"}
|
{"name": "attributes", "type": "vertex attribute", "annotation": "const*", "length": "attribute count"}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"input step mode": {
|
|
||||||
"category": "typedef",
|
|
||||||
"type": "vertex step mode"
|
|
||||||
},
|
|
||||||
"vertex step mode": {
|
"vertex step mode": {
|
||||||
"category": "enum",
|
"category": "enum",
|
||||||
"values": [
|
"values": [
|
||||||
|
@ -1350,11 +1346,6 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
"render pass color attachment descriptor": {
|
|
||||||
"category": "typedef",
|
|
||||||
"type": "render pass color attachment"
|
|
||||||
},
|
|
||||||
|
|
||||||
"render pass depth stencil attachment": {
|
"render pass depth stencil attachment": {
|
||||||
"category": "structure",
|
"category": "structure",
|
||||||
"members": [
|
"members": [
|
||||||
|
@ -1371,11 +1362,6 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
"render pass depth stencil attachment descriptor": {
|
|
||||||
"category": "typedef",
|
|
||||||
"type": "render pass depth stencil attachment"
|
|
||||||
},
|
|
||||||
|
|
||||||
"render pass descriptor": {
|
"render pass descriptor": {
|
||||||
"category": "structure",
|
"category": "structure",
|
||||||
"extensible": true,
|
"extensible": true,
|
||||||
|
|
|
@ -108,7 +108,7 @@ void init() {
|
||||||
void frame() {
|
void frame() {
|
||||||
WGPUTextureView backbufferView = wgpuSwapChainGetCurrentTextureView(swapchain);
|
WGPUTextureView backbufferView = wgpuSwapChainGetCurrentTextureView(swapchain);
|
||||||
WGPURenderPassDescriptor renderpassInfo = {};
|
WGPURenderPassDescriptor renderpassInfo = {};
|
||||||
WGPURenderPassColorAttachmentDescriptor colorAttachment = {};
|
WGPURenderPassColorAttachment colorAttachment = {};
|
||||||
{
|
{
|
||||||
colorAttachment.attachment = backbufferView;
|
colorAttachment.attachment = backbufferView;
|
||||||
colorAttachment.resolveTarget = nullptr;
|
colorAttachment.resolveTarget = nullptr;
|
||||||
|
|
|
@ -163,9 +163,8 @@ namespace dawn_native {
|
||||||
return {};
|
return {};
|
||||||
}
|
}
|
||||||
|
|
||||||
MaybeError ValidateResolveTarget(
|
MaybeError ValidateResolveTarget(const DeviceBase* device,
|
||||||
const DeviceBase* device,
|
const RenderPassColorAttachment& colorAttachment) {
|
||||||
const RenderPassColorAttachmentDescriptor& colorAttachment) {
|
|
||||||
if (colorAttachment.resolveTarget == nullptr) {
|
if (colorAttachment.resolveTarget == nullptr) {
|
||||||
return {};
|
return {};
|
||||||
}
|
}
|
||||||
|
@ -217,7 +216,7 @@ namespace dawn_native {
|
||||||
|
|
||||||
MaybeError ValidateRenderPassColorAttachment(
|
MaybeError ValidateRenderPassColorAttachment(
|
||||||
DeviceBase* device,
|
DeviceBase* device,
|
||||||
const RenderPassColorAttachmentDescriptor& colorAttachment,
|
const RenderPassColorAttachment& colorAttachment,
|
||||||
uint32_t* width,
|
uint32_t* width,
|
||||||
uint32_t* height,
|
uint32_t* height,
|
||||||
uint32_t* sampleCount) {
|
uint32_t* sampleCount) {
|
||||||
|
@ -274,7 +273,7 @@ namespace dawn_native {
|
||||||
|
|
||||||
MaybeError ValidateRenderPassDepthStencilAttachment(
|
MaybeError ValidateRenderPassDepthStencilAttachment(
|
||||||
DeviceBase* device,
|
DeviceBase* device,
|
||||||
const RenderPassDepthStencilAttachmentDescriptor* depthStencilAttachment,
|
const RenderPassDepthStencilAttachment* depthStencilAttachment,
|
||||||
uint32_t* width,
|
uint32_t* width,
|
||||||
uint32_t* height,
|
uint32_t* height,
|
||||||
uint32_t* sampleCount) {
|
uint32_t* sampleCount) {
|
||||||
|
|
|
@ -405,7 +405,7 @@ namespace dawn_native {
|
||||||
device->CreateTextureView(destination->texture, &dstTextureViewDesc));
|
device->CreateTextureView(destination->texture, &dstTextureViewDesc));
|
||||||
|
|
||||||
// Prepare render pass color attachment descriptor.
|
// Prepare render pass color attachment descriptor.
|
||||||
RenderPassColorAttachmentDescriptor colorAttachmentDesc;
|
RenderPassColorAttachment colorAttachmentDesc;
|
||||||
|
|
||||||
colorAttachmentDesc.view = dstView.Get();
|
colorAttachmentDesc.view = dstView.Get();
|
||||||
colorAttachmentDesc.loadOp = wgpu::LoadOp::Load;
|
colorAttachmentDesc.loadOp = wgpu::LoadOp::Load;
|
||||||
|
|
|
@ -42,7 +42,7 @@ TEST_P(DeprecationTests, SetAttachmentDescriptorAttachment) {
|
||||||
wgpu::RenderPassEncoder pass;
|
wgpu::RenderPassEncoder pass;
|
||||||
|
|
||||||
// Check that using .attachment with color attachments gives the warning.
|
// Check that using .attachment with color attachments gives the warning.
|
||||||
wgpu::RenderPassColorAttachmentDescriptor* colorAttachment =
|
wgpu::RenderPassColorAttachment* colorAttachment =
|
||||||
&renderPass.renderPassInfo.cColorAttachments[0];
|
&renderPass.renderPassInfo.cColorAttachments[0];
|
||||||
colorAttachment->attachment = colorAttachment->view;
|
colorAttachment->attachment = colorAttachment->view;
|
||||||
colorAttachment->view = nullptr;
|
colorAttachment->view = nullptr;
|
||||||
|
@ -63,7 +63,7 @@ TEST_P(DeprecationTests, SetAttachmentDescriptorAttachment) {
|
||||||
descriptor.usage = wgpu::TextureUsage::RenderAttachment;
|
descriptor.usage = wgpu::TextureUsage::RenderAttachment;
|
||||||
wgpu::Texture depthStencil = device.CreateTexture(&descriptor);
|
wgpu::Texture depthStencil = device.CreateTexture(&descriptor);
|
||||||
|
|
||||||
wgpu::RenderPassDepthStencilAttachmentDescriptor* depthAttachment =
|
wgpu::RenderPassDepthStencilAttachment* depthAttachment =
|
||||||
&renderPass.renderPassInfo.cDepthStencilAttachmentInfo;
|
&renderPass.renderPassInfo.cDepthStencilAttachmentInfo;
|
||||||
renderPass.renderPassInfo.depthStencilAttachment = depthAttachment;
|
renderPass.renderPassInfo.depthStencilAttachment = depthAttachment;
|
||||||
depthAttachment->attachment = depthStencil.CreateView();
|
depthAttachment->attachment = depthStencil.CreateView();
|
||||||
|
@ -106,7 +106,7 @@ TEST_P(DeprecationTests, StoreOpClear) {
|
||||||
descriptor.usage = wgpu::TextureUsage::RenderAttachment;
|
descriptor.usage = wgpu::TextureUsage::RenderAttachment;
|
||||||
wgpu::Texture depthStencil = device.CreateTexture(&descriptor);
|
wgpu::Texture depthStencil = device.CreateTexture(&descriptor);
|
||||||
|
|
||||||
wgpu::RenderPassDepthStencilAttachmentDescriptor* depthAttachment =
|
wgpu::RenderPassDepthStencilAttachment* depthAttachment =
|
||||||
&renderPass.renderPassInfo.cDepthStencilAttachmentInfo;
|
&renderPass.renderPassInfo.cDepthStencilAttachmentInfo;
|
||||||
renderPass.renderPassInfo.depthStencilAttachment = depthAttachment;
|
renderPass.renderPassInfo.depthStencilAttachment = depthAttachment;
|
||||||
depthAttachment->view = depthStencil.CreateView();
|
depthAttachment->view = depthStencil.CreateView();
|
||||||
|
|
|
@ -101,8 +101,7 @@ namespace {
|
||||||
|
|
||||||
// Test OOB color attachment indices are handled
|
// Test OOB color attachment indices are handled
|
||||||
TEST_F(RenderPassDescriptorValidationTest, ColorAttachmentOutOfBounds) {
|
TEST_F(RenderPassDescriptorValidationTest, ColorAttachmentOutOfBounds) {
|
||||||
std::array<wgpu::RenderPassColorAttachmentDescriptor, kMaxColorAttachments + 1>
|
std::array<wgpu::RenderPassColorAttachment, kMaxColorAttachments + 1> colorAttachments;
|
||||||
colorAttachments;
|
|
||||||
for (uint32_t i = 0; i < colorAttachments.size(); i++) {
|
for (uint32_t i = 0; i < colorAttachments.size(); i++) {
|
||||||
colorAttachments[i].view =
|
colorAttachments[i].view =
|
||||||
Create2DAttachment(device, 1, 1, wgpu::TextureFormat::RGBA8Unorm);
|
Create2DAttachment(device, 1, 1, wgpu::TextureFormat::RGBA8Unorm);
|
||||||
|
|
|
@ -91,7 +91,7 @@ class ValidationTest : public testing::Test {
|
||||||
uint32_t height;
|
uint32_t height;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
wgpu::RenderPassColorAttachmentDescriptor mColorAttachment;
|
wgpu::RenderPassColorAttachment mColorAttachment;
|
||||||
};
|
};
|
||||||
|
|
||||||
bool HasToggleEnabled(const char* toggle) const;
|
bool HasToggleEnabled(const char* toggle) const;
|
||||||
|
|
|
@ -66,9 +66,8 @@ namespace utils {
|
||||||
const ComboRenderPassDescriptor& operator=(
|
const ComboRenderPassDescriptor& operator=(
|
||||||
const ComboRenderPassDescriptor& otherRenderPass);
|
const ComboRenderPassDescriptor& otherRenderPass);
|
||||||
|
|
||||||
std::array<wgpu::RenderPassColorAttachmentDescriptor, kMaxColorAttachments>
|
std::array<wgpu::RenderPassColorAttachment, kMaxColorAttachments> cColorAttachments;
|
||||||
cColorAttachments;
|
wgpu::RenderPassDepthStencilAttachment cDepthStencilAttachmentInfo = {};
|
||||||
wgpu::RenderPassDepthStencilAttachmentDescriptor cDepthStencilAttachmentInfo = {};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct BasicRenderPass {
|
struct BasicRenderPass {
|
||||||
|
|
Loading…
Reference in New Issue