Skip to content

Commit caffc71

Browse files
committed
Make FES accept WEBGPU as a renderer mode
1 parent a44ef09 commit caffc71

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

docs/parameterData.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@
410410
[
411411
"Number?",
412412
"Number?",
413-
"P2D|WEBGL|P2DHDR?",
413+
"P2D|WEBGL|P2DHDR|WEBGPU?",
414414
"HTMLCanvasElement?"
415415
],
416416
[

src/core/rendering.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function rendering(p5, fn){
3333
* the sketch's rendering mode. If an existing
3434
* <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement" target="_blank">HTMLCanvasElement</a>
3535
* is passed, as in `createCanvas(900, 500, myCanvas)`, then it will be used
36-
* by the sketch.
36+
* by the sketch. To use `WEBGPU` mode, make sure you have the WebGPU mode addon included.
3737
*
3838
* The fourth parameter is also optional. If an existing
3939
* <a href="https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement" target="_blank">HTMLCanvasElement</a>
@@ -48,7 +48,7 @@ function rendering(p5, fn){
4848
* @method createCanvas
4949
* @param {Number} [width] width of the canvas. Defaults to 100.
5050
* @param {Number} [height] height of the canvas. Defaults to 100.
51-
* @param {(P2D|WEBGL|P2DHDR)} [renderer] either P2D or WEBGL. Defaults to `P2D`.
51+
* @param {(P2D|WEBGL|P2DHDR|WEBGPU)} [renderer] either P2D, WEBGL, or WEBGPU. Defaults to `P2D`.
5252
* @param {HTMLCanvasElement} [canvas] existing canvas element that should be used for the sketch.
5353
* @return {p5.Renderer} new `p5.Renderer` that holds the canvas.
5454
*

0 commit comments

Comments
 (0)