Skip to content

Commit 17992d7

Browse files
committed
updated .modify() links
1 parent be56924 commit 17992d7

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

src/webgl/ShaderGenerator.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1645,7 +1645,7 @@ if (typeof p5 !== 'undefined') {
16451645
/**
16461646
* @method getWorldInputs
16471647
* @description
1648-
* Registers a callback to modify the world-space properties of each vertex in a shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to customize vertex positions, normals, texture coordinates, and colors before rendering. "World space" refers to the coordinate system of the 3D scene, before any camera or projection transformations are applied.
1648+
* Registers a callback to modify the world-space properties of each vertex in a shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to customize vertex positions, normals, texture coordinates, and colors before rendering. "World space" refers to the coordinate system of the 3D scene, before any camera or projection transformations are applied.
16491649
*
16501650
* The callback receives a vertex object with the following properties:
16511651
* - `position`: a three-component vector representing the original position of the vertex.
@@ -1694,7 +1694,7 @@ if (typeof p5 !== 'undefined') {
16941694
/**
16951695
* @method combineColors
16961696
* @description
1697-
* Registers a callback to customize how color components are combined in the fragment shader. This hook can be used inside <a href="#/p5/baseMaterialShader">baseMaterialShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to control the final color output of a material. The callback receives an object with the following properties:
1697+
* Registers a callback to customize how color components are combined in the fragment shader. This hook can be used inside <a href="#/p5/baseMaterialShader">baseMaterialShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to control the final color output of a material. The callback receives an object with the following properties:
16981698
*
16991699
* - `baseColor`: a three-component vector representing the base color (red, green, blue).
17001700
* - `diffuse`: a single number representing the diffuse reflection.
@@ -1749,7 +1749,7 @@ if (typeof p5 !== 'undefined') {
17491749
* @method beforeVertex
17501750
* @private
17511751
* @description
1752-
* Registers a callback to run custom code at the very start of the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to set up variables or perform calculations that affect every vertex before processing begins. The callback receives no arguments.
1752+
* Registers a callback to run custom code at the very start of the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to set up variables or perform calculations that affect every vertex before processing begins. The callback receives no arguments.
17531753
*
17541754
* Note: This hook is currently limited to per-vertex operations; storing variables for later use is not supported.
17551755
*
@@ -1767,7 +1767,7 @@ if (typeof p5 !== 'undefined') {
17671767
* @method afterVertex
17681768
* @private
17691769
* @description
1770-
* Registers a callback to run custom code at the very end of the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to perform cleanup or final calculations after all vertex processing is done. The callback receives no arguments.
1770+
* Registers a callback to run custom code at the very end of the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to perform cleanup or final calculations after all vertex processing is done. The callback receives no arguments.
17711771
*
17721772
* Note: This hook is currently limited to per-vertex operations; storing variables for later use is not supported.
17731773
*
@@ -1785,7 +1785,7 @@ if (typeof p5 !== 'undefined') {
17851785
* @method beforeFragment
17861786
* @private
17871787
* @description
1788-
* Registers a callback to run custom code at the very start of the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to set up variables or perform calculations that affect every pixel before color calculations begin. The callback receives no arguments.
1788+
* Registers a callback to run custom code at the very start of the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to set up variables or perform calculations that affect every pixel before color calculations begin. The callback receives no arguments.
17891789
*
17901790
* This hook is available in:
17911791
* - <a href="#/p5/baseColorShader">baseColorShader()</a>
@@ -1828,7 +1828,7 @@ if (typeof p5 !== 'undefined') {
18281828
/**
18291829
* @method getPixelInputs
18301830
* @description
1831-
* Registers a callback to modify the properties of each fragment (pixel) before the final color is calculated in the fragment shader. This hook can be used inside <a href="#/p5/baseMaterialShader">baseMaterialShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to adjust per-pixel data before lighting/mixing.
1831+
* Registers a callback to modify the properties of each fragment (pixel) before the final color is calculated in the fragment shader. This hook can be used inside <a href="#/p5/baseMaterialShader">baseMaterialShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to adjust per-pixel data before lighting/mixing.
18321832
*
18331833
* The callback receives an `Inputs` object. Available fields depend on the shader:
18341834
*
@@ -1890,7 +1890,7 @@ if (typeof p5 !== 'undefined') {
18901890
* @method shouldDiscard
18911891
* @private
18921892
* @description
1893-
* Registers a callback to decide whether to discard (skip drawing) a fragment (pixel) in the fragment shader. This hook can be used inside <a href="#/p5/baseStrokeShader">baseStrokeShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to create effects like round points or custom masking. The callback receives a boolean:
1893+
* Registers a callback to decide whether to discard (skip drawing) a fragment (pixel) in the fragment shader. This hook can be used inside <a href="#/p5/baseStrokeShader">baseStrokeShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to create effects like round points or custom masking. The callback receives a boolean:
18941894
* - `willDiscard`: true if the fragment would be discarded by default
18951895
*
18961896
* Return true to discard the fragment, or false to keep it.
@@ -1924,7 +1924,7 @@ if (typeof p5 !== 'undefined') {
19241924
/**
19251925
* @method getFinalColor
19261926
* @description
1927-
* Registers a callback to change the final color of each pixel after all lighting and mixing is done in the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to adjust the color before it appears on the screen. The callback receives a four component vector representing red, green, blue, and alpha.
1927+
* Registers a callback to change the final color of each pixel after all lighting and mixing is done in the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to adjust the color before it appears on the screen. The callback receives a four component vector representing red, green, blue, and alpha.
19281928
*
19291929
* Return a new color array to change the output color.
19301930
*
@@ -1966,7 +1966,7 @@ if (typeof p5 !== 'undefined') {
19661966
* @method afterFragment
19671967
* @private
19681968
* @description
1969-
* Registers a callback to run custom code at the very end of the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to perform cleanup or final per-pixel effects after all color calculations are done. The callback receives no arguments.
1969+
* Registers a callback to run custom code at the very end of the fragment shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to perform cleanup or final per-pixel effects after all color calculations are done. The callback receives no arguments.
19701970
*
19711971
* This hook is available in:
19721972
* - <a href="#/p5/baseColorShader">baseColorShader()</a>
@@ -2009,7 +2009,7 @@ if (typeof p5 !== 'undefined') {
20092009
/**
20102010
* @method getColor
20112011
* @description
2012-
* Registers a callback to set the final color for each pixel in a filter shader. This hook can be used inside <a href="#/p5/baseFilterShader">baseFilterShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to control the output color for each pixel. The callback receives the following arguments:
2012+
* Registers a callback to set the final color for each pixel in a filter shader. This hook can be used inside <a href="#/p5/baseFilterShader">baseFilterShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to control the output color for each pixel. The callback receives the following arguments:
20132013
* - `inputs`: an object with the following properties:
20142014
* - `texCoord`: a two-component vector representing the texture coordinates (u, v).
20152015
* - `canvasSize`: a two-component vector representing the canvas size in pixels (width, height).
@@ -2052,7 +2052,7 @@ if (typeof p5 !== 'undefined') {
20522052
/**
20532053
* @method getObjectInputs
20542054
* @description
2055-
* Registers a callback to modify the properties of each vertex before any transformations are applied in the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to move, color, or otherwise modify the raw model data. The callback receives an object with the following properties:
2055+
* Registers a callback to modify the properties of each vertex before any transformations are applied in the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to move, color, or otherwise modify the raw model data. The callback receives an object with the following properties:
20562056
*
20572057
* - `position`: a three-component vector representing the original position of the vertex.
20582058
* - `normal`: a three-component vector representing the direction the surface is facing.
@@ -2099,7 +2099,7 @@ if (typeof p5 !== 'undefined') {
20992099
/**
21002100
* @method getCameraInputs
21012101
* @description
2102-
* Registers a callback to adjust vertex properties after the model has been transformed by the camera, but before projection, in the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify</a> calls to create effects that depend on the camera's view. The callback receives an object with the following properties:
2102+
* Registers a callback to adjust vertex properties after the model has been transformed by the camera, but before projection, in the vertex shader. This hook can be used inside <a href="#/p5/baseColorShader">baseColorShader()</a>.modify() and similar shader <a href="#/p5.Shader/modify">modify()</a> calls to create effects that depend on the camera's view. The callback receives an object with the following properties:
21032103
*
21042104
* - `position`: a three-component vector representing the position after camera transformation.
21052105
* - `normal`: a three-component vector representing the normal after camera transformation.

0 commit comments

Comments
 (0)