Commit c76f0d78 authored by François Beaufort's avatar François Beaufort Committed by Commit Bot

[WebGPU] Replaced "long" with "unsigned long" for stencilLoadValue

https://gpuweb.github.io/gpuweb/#depth-stencil-attachments says
stencilLoadValue is "unsigned long", not "long". This CL fixes it.

Bug: 877147
Change-Id: I73592bc24800ee15c1b105473f6e79a52e8abe57
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1815019Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Reviewed-by: default avatarCorentin Wallez <cwallez@chromium.org>
Commit-Queue: François Beaufort <beaufort.francois@gmail.com>
Cr-Commit-Position: refs/heads/master@{#699339}
parent d84a3244
......@@ -52,8 +52,8 @@ bindings_modules_generated_union_type_files = [
"$bindings_modules_v8_output_dir/gpu_load_op_or_gpu_color.h",
"$bindings_modules_v8_output_dir/gpu_load_op_or_float.cc",
"$bindings_modules_v8_output_dir/gpu_load_op_or_float.h",
"$bindings_modules_v8_output_dir/gpu_load_op_or_long.cc",
"$bindings_modules_v8_output_dir/gpu_load_op_or_long.h",
"$bindings_modules_v8_output_dir/gpu_load_op_or_unsigned_long.cc",
"$bindings_modules_v8_output_dir/gpu_load_op_or_unsigned_long.h",
"$bindings_modules_v8_output_dir/gpu_sampler_or_gpu_texture_view_or_gpu_buffer_binding.cc",
"$bindings_modules_v8_output_dir/gpu_sampler_or_gpu_texture_view_or_gpu_buffer_binding.h",
"$bindings_modules_v8_output_dir/html_canvas_element_or_offscreen_canvas.cc",
......
......@@ -82,9 +82,10 @@ DawnRenderPassDepthStencilAttachmentDescriptor AsDawnType(
dawn_desc.stencilLoadOp = AsDawnEnum<DawnLoadOp>(gpuLoadOp);
dawn_desc.clearStencil = 0;
} else if (webgpu_desc->stencilLoadValue().IsLong()) {
} else if (webgpu_desc->stencilLoadValue().IsUnsignedLong()) {
dawn_desc.stencilLoadOp = DAWN_LOAD_OP_CLEAR;
dawn_desc.clearStencil = webgpu_desc->stencilLoadValue().GetAsLong();
dawn_desc.clearStencil =
webgpu_desc->stencilLoadValue().GetAsUnsignedLong();
} else {
NOTREACHED();
......
......@@ -10,6 +10,6 @@ dictionary GPURenderPassDepthStencilAttachmentDescriptor {
required (GPULoadOp or float) depthLoadValue;
required GPUStoreOp depthStoreOp;
required (GPULoadOp or long) stencilLoadValue;
required (GPULoadOp or unsigned long) stencilLoadValue;
required GPUStoreOp stencilStoreOp;
};
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment