@@ -30,7 +30,7 @@ require('./error_helpers');
30
30
* @param {Number } y3 y-coordinate for the second control point
31
31
* @param {Number } x4 x-coordinate for the second anchor point
32
32
* @param {Number } y4 y-coordinate for the second anchor point
33
- * @return { p5 } the p5 object
33
+ * @chainable
34
34
* @example
35
35
* <div>
36
36
* <code>
@@ -42,6 +42,16 @@ require('./error_helpers');
42
42
* bezier(85, 20, 10, 10, 90, 90, 15, 80);
43
43
* </code>
44
44
* </div>
45
+ *
46
+ * <div>
47
+ * <code>
48
+ * background(0, 0, 0);
49
+ * noFill();
50
+ * stroke(255);
51
+ * bezier(250, 250, 0, 100, 100, 0, 100, 0, 0, 0, 100, 0);
52
+ * </code>
53
+ * </div>
54
+ *
45
55
* @alt
46
56
* stretched black s-shape in center with orange lines extending from end points.
47
57
* stretched black s-shape with 10 5x5 white ellipses along the shape.
@@ -55,20 +65,19 @@ require('./error_helpers');
55
65
*/
56
66
/**
57
67
* @method bezier
68
+ * @param {Number } x1
69
+ * @param {Number } y1
58
70
* @param {Number } z1 z-coordinate for the first anchor point
71
+ * @param {Number } x2
72
+ * @param {Number } y2
59
73
* @param {Number } z2 z-coordinate for the first control point
60
- * @param {Number } z3 z-coordinate for the first anchor point
61
- * @param {Number } z4 z-coordinate for the first control point
74
+ * @param {Number } x3
75
+ * @param {Number } y3
76
+ * @param {Number } z3 z-coordinate for the second control point
77
+ * @param {Number } x4
78
+ * @param {Number } y4
79
+ * @param {Number } z4 z-coordinate for the second anchor point
62
80
* @chainable
63
- * @example
64
- * <div>
65
- * <code>
66
- *background(0, 0, 0);
67
- *noFill();
68
- *stroke(255);
69
- *bezier(250, 250, 0, 100, 100, 0, 100, 0, 0, 0, 100, 0);
70
- * </code>
71
- * </div>
72
81
*/
73
82
p5 . prototype . bezier = function ( ) {
74
83
p5 . _validateParameters ( 'bezier' , arguments ) ;
@@ -260,7 +269,7 @@ p5.prototype.bezierTangent = function(a, b, c, d, t) {
260
269
* @param {Number } y3 y-coordinate for the second point
261
270
* @param {Number } x4 x-coordinate for the ending control point
262
271
* @param {Number } y4 y-coordinate for the ending control point
263
- * @return { p5 } the p5 object
272
+ * @chainable
264
273
* @example
265
274
* <div>
266
275
* <code>
@@ -289,20 +298,6 @@ p5.prototype.bezierTangent = function(a, b, c, d, t) {
289
298
* curve(p2.x, p2.y, p3.x, p3.y, p4.x, p4.y, p4.x, p4.y);
290
299
* </code>
291
300
* </div>
292
- *
293
- * @alt
294
- * horseshoe shape with orange ends facing left and black curved center.
295
- * horseshoe shape with orange ends facing left and black curved center.
296
- *
297
- */
298
- /**
299
- * @method curve
300
- * @param {Number } z1 z-coordinate for the beginning control point
301
- * @param {Number } z2 z-coordinate for the first point
302
- * @param {Number } z3 z-coordinate for the second point
303
- * @param {Number } z4 z-coordinate for the ending control point
304
- * @chainable
305
- * @example
306
301
* <div>
307
302
* <code>
308
303
* noFill();
@@ -316,8 +311,26 @@ p5.prototype.bezierTangent = function(a, b, c, d, t) {
316
311
* </div>
317
312
*
318
313
* @alt
314
+ * horseshoe shape with orange ends facing left and black curved center.
315
+ * horseshoe shape with orange ends facing left and black curved center.
319
316
* curving black and orange lines.
320
317
*/
318
+ /**
319
+ * @method curve
320
+ * @param {Number } x1
321
+ * @param {Number } y1
322
+ * @param {Number } z1 z-coordinate for the beginning control point
323
+ * @param {Number } x2
324
+ * @param {Number } y2
325
+ * @param {Number } z2 z-coordinate for the first point
326
+ * @param {Number } x3
327
+ * @param {Number } y3
328
+ * @param {Number } z3 z-coordinate for the second point
329
+ * @param {Number } x4
330
+ * @param {Number } y4
331
+ * @param {Number } z4 z-coordinate for the ending control point
332
+ * @chainable
333
+ */
321
334
p5 . prototype . curve = function ( ) {
322
335
p5 . _validateParameters ( 'curve' , arguments ) ;
323
336
0 commit comments