frameRate([fps])
Sets the framerate per second to determine how often loop()
is called per second. If the processor is not fast enough to maintain the specified rate, the frame rate will not be achieved. Setting the frame rate within setup()
is recommended. The default rate is 25 frames per second. Calling frameRate()
with no arguments returns the currently set framerate.
Type: function
Parameter(s):
- fps {Number} Optional:
Frames per second.
Returns:
-
{Number}:
Currently set frame rate.