recfps#
optionoav-p5?oav_recfps=1 to 60
The frame rate of recorded video, 1 to 60 frames a second.
How many frames a second the recorder takes from the canvas, for startRecording() and the ⏺ button. 30 suits most places Instagram and YouTube accept. 60 is smoother for fast motion and makes a bigger file. One take can ask for its own rate: startRecording({ fps: 60 }).
- Type
Number- Values
1 to 60- default
30
Rounded to a whole number and held between 1 and 60. Anything that is not a number means 30.
Notes
- It is read back as
OAVp5.options.recfpsand asOAVp5.record.fps. - Set it before oav-p5 loads.
window.OAV_P5 = { recfps: … };above the loader line wins, then?oav_recfps=…on the page address, then?recfps=…on the script's own URL. Values inwindow.OAV_P5are turned into text, so write'off', notfalse. On OpenProcessing the page address takes?sketch_oav_recfps=…(the project's README says OpenProcessing forwards it to the sketch).
Examples
window.OAV_P5 = { recfps: 60 };
function setup() {
createCanvas(400, 300);
}
function draw() {
background(20);
fill(255);
text('recording frame rate: ' + OAVp5.record.fps, 20, 30);
}Related
reclimitThe longest one recording may last, in seconds: a take stops by itself there.recordWhether recording is available and whether it includes the microphone:on,nomicoroff.startRecording()Records the canvas and the sound your sketch makes into one video file, and returns a promise that says whether the recording began.OAVp5.record.fpsThe frame rate (fps) and the longest take in seconds (limit) that the loading optionsrecfpsandreclimitset.