Skip to content

Commit

Permalink
Updated inline docs for linePerspective()
Browse files Browse the repository at this point in the history
  • Loading branch information
Garima3110 committed Jan 12, 2024
1 parent ba0f02e commit 656f80c
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/webgl/p5.RendererGL.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,21 @@ const defineStrokeJoinEnum = function (key, val) {
STROKE_JOIN_ENUM[constants[key]] = val;
};

/**
*
* Enable or disable perspective for lines in the WebGL renderer.
* When linePerspective is enabled, lines will be affected by the current camera's perspective.
* When linePerspective is disabled, lines will have a uniform scale regardless of the camera's perspective.
*
* @method linePerspective
* @memberof p5.prototype
* @param {boolean} enable - Set to `true` to enable line perspective, `false` to disable.
*<br>
* @example
* @TODO
*/

p5.prototype.linePerspective = function (enable) {
if (enable) {
this.drawingContext.linePerspective = true;
Expand Down

0 comments on commit 656f80c

Please sign in to comment.