diff --git a/docs/parameterData.json b/docs/parameterData.json index 055a8853de..6fd69e51ad 100644 --- a/docs/parameterData.json +++ b/docs/parameterData.json @@ -934,7 +934,7 @@ "image": { "overloads": [ [ - "p5.Image|p5.Element|p5.Texture|p5.Framebuffer|p5.FramebufferTexture", + "p5.Image|p5.Element|p5.Texture|p5.Framebuffer|p5.FramebufferTexture|p5.Renderer|p5.Graphics", "Number", "Number", "Number?", @@ -1431,13 +1431,6 @@ ] ] }, - "createMatrix": { - "overloads": [ - [ - "Number[]" - ] - ] - }, "noise": { "overloads": [ [ @@ -1856,14 +1849,23 @@ }, "bezierOrder": { "overloads": [ - [], [ "Number" - ] + ], + [] ] }, "splineVertex": { "overloads": [ + [ + "Number", + "Number" + ], + [ + "Number", + "Number", + "Number?" + ], [ "Number", "Number", @@ -1881,21 +1883,21 @@ }, "splineProperty": { "overloads": [ - [ - "String" - ], [ "String", null + ], + [ + "String" ] ] }, "splineProperties": { "overloads": [ - [], [ "Object" - ] + ], + [] ] }, "vertex": { @@ -1955,19 +1957,6 @@ ] ] }, - "curveVertex": { - "overloads": [ - [ - "Number", - "Number" - ], - [ - "Number", - "Number", - "Number?" - ] - ] - }, "endShape": { "overloads": [ [ @@ -2755,36 +2744,6 @@ ] ] }, - "parseObj": { - "overloads": [ - [] - ] - }, - "parseSTL": { - "overloads": [ - [] - ] - }, - "isBinary": { - "overloads": [ - [] - ] - }, - "matchDataViewAt": { - "overloads": [ - [] - ] - }, - "parseBinarySTL": { - "overloads": [ - [] - ] - }, - "parseASCIISTL": { - "overloads": [ - [] - ] - }, "model": { "overloads": [ [ diff --git a/src/image/loading_displaying.js b/src/image/loading_displaying.js index 567bdcba90..a4e321f6ce 100644 --- a/src/image/loading_displaying.js +++ b/src/image/loading_displaying.js @@ -903,7 +903,7 @@ function loadingDisplaying(p5, fn){ * are set to `CENTER`. * * @method image - * @param {p5.Image|p5.Element|p5.Texture|p5.Framebuffer|p5.FramebufferTexture} img image to display. + * @param {p5.Image|p5.Element|p5.Texture|p5.Framebuffer|p5.FramebufferTexture|p5.Renderer|p5.Graphics} img image to display. * @param {Number} x x-coordinate of the top-left corner of the image. * @param {Number} y y-coordinate of the top-left corner of the image. * @param {Number} [width] width to draw the image. diff --git a/test/unit/core/param_errors.js b/test/unit/core/param_errors.js index ed3857b84d..4c929d80c8 100644 --- a/test/unit/core/param_errors.js +++ b/test/unit/core/param_errors.js @@ -22,6 +22,12 @@ suite('Validate Params', function () { FramebufferTexture: function() { return 'mock p5.FramebufferTexture'; }, + Renderer: function() { + return 'mock p5.Renderer'; + }, + Graphics: function() { + return 'mock p5.Graphics'; + }, _error: () => {}, }; const mockP5Prototype = {}; @@ -124,7 +130,7 @@ suite('Validate Params', function () { console.log(result); assert.equal( result.error, - '🌸 p5.js says: Did you mean to put `await` before a loading function? An unexpected Promise was found. Expected Image or Element or Texture or Framebuffer or FramebufferTexture at the first parameter in p5.image().' + '🌸 p5.js says: Did you mean to put `await` before a loading function? An unexpected Promise was found. Expected Image or Element or Texture or Framebuffer or FramebufferTexture or Renderer or Graphics at the first parameter in p5.image().' ); }); });