Updates the canvas with the RGBA values in the pixels array.
updatePixels()
only needs to be called after changing values in the pixels array. Such changes can be made directly after calling loadPixels() or by calling set().
Examples
Syntax
updatePixels([x], [y], [w], [h])
updatePixels()
Parameters
x
Number: x-coordinate of the upper-left corner of region to update.
y
Number: y-coordinate of the upper-left corner of region to update.
w
Number: width of region to update.
h
Number: height of region to update.
Notice any errors or typos? Please let us know. Please feel free to edit src/webgl/p5.Framebuffer.js and open a pull request!
Related References
textToContours
Returns an array of arrays of points outlining a string of text written using the font.
textToModel
Converts text into a 3D model that can be rendered in WebGL mode.
textToPaths
Returns a flat array of path commands that describe the outlines of a string of text.
textToPoints
Returns an array of points outlining a string of text written using the font.