[webkit-changes] [WebKit/WebKit] c73629: [WebGPU] Handle constants on vertex and fragment s...

Tadeu Zagallo noreply at github.com
Fri Apr 21 01:36:13 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: c736295c82d42d2a749584588602348e7e2fe70c
      https://github.com/WebKit/WebKit/commit/c736295c82d42d2a749584588602348e7e2fe70c
  Author: Tadeu Zagallo <tzagallo at apple.com>
  Date:   2023-04-21 (Fri, 21 Apr 2023)

  Changed paths:
    M Source/WebGPU/WebGPU/ComputePipeline.mm
    M Source/WebGPU/WebGPU/Pipeline.h
    M Source/WebGPU/WebGPU/Pipeline.mm
    M Source/WebGPU/WebGPU/RenderPipeline.mm

  Log Message:
  -----------
  [WebGPU] Handle constants on vertex and fragment shaders
https://bugs.webkit.org/show_bug.cgi?id=255663
rdar://108267496

Reviewed by Mike Wyrzykowski.

Mild refactor of the `createFunction` helper function, which used take a
`WGPUProgrammableStageDescriptor`, and therefore would only populate constants
for compute shaders. Instead we pass the relevant information (constant count and
pointer) directly, so that we can also use it with vertex and fragment descriptors.

* Source/WebGPU/WebGPU/ComputePipeline.mm:
(WebGPU::Device::createComputePipeline):
* Source/WebGPU/WebGPU/Pipeline.h:
* Source/WebGPU/WebGPU/Pipeline.mm:
(WebGPU::createFunction):
* Source/WebGPU/WebGPU/RenderPipeline.mm:
(WebGPU::Device::createRenderPipeline):

Canonical link: https://commits.webkit.org/263221@main




More information about the webkit-changes mailing list