open-audiovisual
Search GitHub

oav-p5 reference · Loading options

reclimit#

optionoav-p5
?oav_reclimit=1 or more (seconds)

The longest one recording may last, in seconds: a take stops by itself there.

A long take fills the tab's memory, so every recording stops by itself at this length, saves what it has and shows a card saying so. Raise it for a long piece, record in parts, or give one take its own length: startRecording(10) stops after ten seconds, and a number above the limit is cut down to the limit.

Type
Number
Values
1 or more (seconds)
default
300

At least 1. Anything that is not a number means 300 (five minutes).

Notes

  • It is read back as OAVp5.options.reclimit and as OAVp5.record.limit.
  • Set it before oav-p5 loads. window.OAV_P5 = { reclimit: … }; above the loader line wins, then ?oav_reclimit=… on the page address, then ?reclimit=… on the script's own URL. Values in window.OAV_P5 are turned into text, so write 'off', not false. On OpenProcessing the page address takes ?sketch_oav_reclimit=… (the project's README says OpenProcessing forwards it to the sketch).

Examples

jsOpenProcessing ↗
window.OAV_P5 = { reclimit: 60 };

function setup() {
  createCanvas(400, 300);
}

function draw() {
  background(20);
  fill(255);
  text('longest take: ' + OAVp5.record.limit + ' seconds', 20, 30);
}
A recording from this page stops by itself after a minute.

Related

  • recfps The frame rate of recorded video, 1 to 60 frames a second.
  • record Whether recording is available and whether it includes the microphone: on, nomic or off.
  • 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.fps The frame rate (fps) and the longest take in seconds (limit) that the loading options recfps and reclimit set.

p5/oav-p5.js, line 133

↑ Back to top · All names