Roll Dawn, fix build issues in Skia Dawn
There were some recent renamings in Skia and in the WGPU API. Roll Dawn to the latest patch, and update Skia Dawn to match these new names. Change-Id: I0b73a514553664ddea7181b9c6174ab6231ea4f8 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/253731 Commit-Queue: Stephen White <senorblanco@chromium.org> Reviewed-by: Stephen White <senorblanco@chromium.org>
This commit is contained in:
parent
2565a6db53
commit
6c536a5b44
2
DEPS
2
DEPS
@ -8,7 +8,7 @@ deps = {
|
||||
"buildtools" : "https://chromium.googlesource.com/chromium/buildtools.git@505de88083136eefd056e5ee4ca0f01fe9b33de8",
|
||||
"common" : "https://skia.googlesource.com/common.git@9737551d7a52c3db3262db5856e6bcd62c462b92",
|
||||
"third_party/externals/angle2" : "https://chromium.googlesource.com/angle/angle.git@012d15196023467be913ef6d537417be91e68e16",
|
||||
"third_party/externals/dawn" : "https://dawn.googlesource.com/dawn.git@2cdf132c0f47ae0305a8977da74c19824c1b36ef",
|
||||
"third_party/externals/dawn" : "https://dawn.googlesource.com/dawn.git@3c086a0c2e1dc3e2e14aaa3d78c052c7e07274b4",
|
||||
"third_party/externals/dng_sdk" : "https://android.googlesource.com/platform/external/dng_sdk.git@c8d0c9b1d16bfda56f15165d39e0ffa360a11123",
|
||||
"third_party/externals/egl-registry" : "https://skia.googlesource.com/external/github.com/KhronosGroup/EGL-Registry@a0bca08de07c7d7651047bedc0b653cfaaa4f2ae",
|
||||
"third_party/externals/expat" : "https://android.googlesource.com/platform/external/expat.git@e5aa0a2cb0a5f759ef31c0819dc67d9b14246a4a",
|
||||
|
@ -148,7 +148,7 @@ void GrDawnOpsRenderPass::applyState(const GrProgramInfo& programInfo) {
|
||||
fPassEncoder.SetBindGroup(0, bindGroup, 0, nullptr);
|
||||
const GrPipeline& pipeline = programInfo.pipeline();
|
||||
if (pipeline.isStencilEnabled()) {
|
||||
fPassEncoder.SetStencilReference(pipeline.getUserStencil()->fFront.fRef);
|
||||
fPassEncoder.SetStencilReference(pipeline.getUserStencil()->fCCWFace.fRef);
|
||||
}
|
||||
GrXferProcessor::BlendInfo blendInfo = pipeline.getXferProcessor().getBlendInfo();
|
||||
const float* c = blendInfo.fBlendConstant.vec();
|
||||
|
@ -243,14 +243,14 @@ static wgpu::DepthStencilStateDescriptor create_depth_stencil_state(
|
||||
state.format = depthStencilFormat;
|
||||
if (!stencilSettings.isDisabled()) {
|
||||
if (stencilSettings.isTwoSided()) {
|
||||
auto front = stencilSettings.front(origin);
|
||||
auto back = stencilSettings.front(origin);
|
||||
auto front = stencilSettings.postOriginCCWFace(origin);
|
||||
auto back = stencilSettings.postOriginCCWFace(origin);
|
||||
state.stencilFront = to_stencil_state_face(front);
|
||||
state.stencilBack = to_stencil_state_face(back);
|
||||
state.stencilReadMask = front.fTestMask;
|
||||
state.stencilWriteMask = front.fWriteMask;
|
||||
} else {
|
||||
auto frontAndBack = stencilSettings.frontAndBack();
|
||||
auto frontAndBack = stencilSettings.singleSidedFace();
|
||||
state.stencilBack = state.stencilFront = to_stencil_state_face(frontAndBack);
|
||||
state.stencilReadMask = frontAndBack.fTestMask;
|
||||
state.stencilWriteMask = frontAndBack.fWriteMask;
|
||||
@ -353,7 +353,7 @@ sk_sp<GrDawnProgram> GrDawnProgramBuilder::Build(GrDawnGpu* gpu,
|
||||
depthStencilState = create_depth_stencil_state(stencil, depthStencilFormat,
|
||||
programInfo.origin());
|
||||
|
||||
std::vector<wgpu::VertexBufferDescriptor> inputs;
|
||||
std::vector<wgpu::VertexBufferLayoutDescriptor> inputs;
|
||||
|
||||
std::vector<wgpu::VertexAttributeDescriptor> vertexAttributes;
|
||||
const GrPrimitiveProcessor& primProc = programInfo.primProc();
|
||||
@ -369,8 +369,8 @@ sk_sp<GrDawnProgram> GrDawnProgramBuilder::Build(GrDawnGpu* gpu,
|
||||
offset += attrib.sizeAlign4();
|
||||
i++;
|
||||
}
|
||||
wgpu::VertexBufferDescriptor input;
|
||||
input.stride = offset;
|
||||
wgpu::VertexBufferLayoutDescriptor input;
|
||||
input.arrayStride = offset;
|
||||
input.stepMode = wgpu::InputStepMode::Vertex;
|
||||
input.attributeCount = vertexAttributes.size();
|
||||
input.attributes = &vertexAttributes.front();
|
||||
@ -389,17 +389,17 @@ sk_sp<GrDawnProgram> GrDawnProgramBuilder::Build(GrDawnGpu* gpu,
|
||||
offset += attrib.sizeAlign4();
|
||||
i++;
|
||||
}
|
||||
wgpu::VertexBufferDescriptor input;
|
||||
input.stride = offset;
|
||||
wgpu::VertexBufferLayoutDescriptor input;
|
||||
input.arrayStride = offset;
|
||||
input.stepMode = wgpu::InputStepMode::Instance;
|
||||
input.attributeCount = instanceAttributes.size();
|
||||
input.attributes = &instanceAttributes.front();
|
||||
inputs.push_back(input);
|
||||
}
|
||||
wgpu::VertexInputDescriptor vertexInput;
|
||||
vertexInput.indexFormat = wgpu::IndexFormat::Uint16;
|
||||
vertexInput.bufferCount = inputs.size();
|
||||
vertexInput.buffers = &inputs.front();
|
||||
wgpu::VertexStateDescriptor vertexState;
|
||||
vertexState.indexFormat = wgpu::IndexFormat::Uint16;
|
||||
vertexState.vertexBufferCount = inputs.size();
|
||||
vertexState.vertexBuffers = &inputs.front();
|
||||
|
||||
wgpu::ProgrammableStageDescriptor vsDesc;
|
||||
vsDesc.module = vsModule;
|
||||
@ -413,7 +413,7 @@ sk_sp<GrDawnProgram> GrDawnProgramBuilder::Build(GrDawnGpu* gpu,
|
||||
rpDesc.layout = pipelineLayout;
|
||||
rpDesc.vertexStage = vsDesc;
|
||||
rpDesc.fragmentStage = &fsDesc;
|
||||
rpDesc.vertexInput = &vertexInput;
|
||||
rpDesc.vertexState = &vertexState;
|
||||
rpDesc.primitiveTopology = to_dawn_primitive_topology(programInfo.primitiveType());
|
||||
if (hasDepthStencil) {
|
||||
rpDesc.depthStencilState = &depthStencilState;
|
||||
|
Loading…
Reference in New Issue
Block a user