Skip to content

Commit a2adbaa

Browse files
docs: resolve PR feedback - revert private docs and fix buildGeometry formatting
1 parent 6770cb9 commit a2adbaa

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

src/core/p5.Renderer3D.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -418,11 +418,12 @@ export class Renderer3D extends Renderer {
418418
/**
419419
* Starts creating a new p5.Geometry. Subsequent shapes drawn will be added
420420
* to the geometry and then returned when
421+
* <a href="#/p5/endGeometry">endGeometry()</a> is called. One can also use
421422
* <a href="#/p5/buildGeometry">buildGeometry()</a> to pass a function that
422423
* draws shapes.
423424
*
424425
* If you need to draw complex shapes every frame which don't change over time,
425-
* combining them upfront with `buildGeometry()` and then
426+
* combining them upfront with `beginGeometry()` and `endGeometry()` and then
426427
* drawing that will run faster than repeatedly drawing the individual pieces.
427428
* @private
428429
*/
@@ -439,7 +440,7 @@ export class Renderer3D extends Renderer {
439440

440441
/**
441442
* Finishes creating a new <a href="#/p5.Geometry">p5.Geometry</a> that was
442-
* One can also
443+
* started using <a href="#/p5/beginGeometry">beginGeometry()</a>. One can also
443444
* use <a href="#/p5/buildGeometry">buildGeometry()</a> to pass a function that
444445
* draws shapes.
445446
* @private
@@ -471,6 +472,9 @@ export class Renderer3D extends Renderer {
471472
* combining them with `buildGeometry()` once and then drawing that will run
472473
* faster than repeatedly drawing the individual pieces.
473474
*
475+
* One can also draw shapes directly between
476+
* <a href="#/p5/beginGeometry">beginGeometry()</a> and
477+
* <a href="#/p5/endGeometry">endGeometry()</a> instead of using a callback
474478
* function.
475479
* @param {Function} callback A function that draws shapes.
476480
* @returns {p5.Geometry} The model that was built from the callback function.

src/webgl/3d_primitives.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,8 @@ function primitives3D(p5, fn){
111111
* will run faster than repeatedly drawing the individual pieces.
112112
*
113113
* The parameter, `callback`, is a function with the drawing instructions for
114-
*
114+
* the new <a href="#/p5.Geometry">p5.Geometry</a> object. It will be called
115+
* once to create the new 3D shape.
115116
* Note: `buildGeometry()` can only be used in WebGL mode.
116117
*
117118
* @method buildGeometry

0 commit comments

Comments
 (0)