Constraints & Negotiation
When you request camera access with getUserMedia(), and later refine it with track.applyConstraints(), the resolution and frame rate you pass in are treated as an ideal, not a strict requirement (unless you explicitly mark them as exact, which will fail outright if unavailable rather than substitute). The browser negotiates with the camera driver to find the closest mode the hardware actually supports, then reports back the real values through track.getSettings().
This tool also calls track.getCapabilities() where the browser supports it, which returns the full range of resolutions and frame rates the camera claims it can produce - useful context for understanding why a particular preset landed where it did.
How FPS Is Measured
Rather than trusting the frame rate value the camera or browser reports in getSettings(), this tool counts frames as they actually arrive. On Chrome, Edge, and other browsers that support it, it uses HTMLVideoElement.requestVideoFrameCallback(), an API specifically designed to fire once per decoded video frame with accurate timing metadata - the most reliable way to count real frames in the browser today.
On browsers without that API (older Safari and Firefox versions), it falls back to a requestAnimationFrame loop that samples video.currentTime on every animation frame and counts each time it advances to a new value - a slightly less precise method (since it's limited by display refresh rate and JS scheduling) but still a genuine, live measurement rather than a static number.
Common Use Cases
Reading the Comparison
| Column | Source | Meaning |
|---|---|---|
| Requested | The preset you selected | What was passed to applyConstraints() as an ideal value |
| Actual (negotiated) | track.getSettings() | What the camera/browser actually settled on |
| FPS measured | requestVideoFrameCallback / rAF sampling | Real frames counted arriving in the video element, live |
A gap between requested and actual is normal and expected - it usually means the camera doesn't natively support that exact combination and the browser picked its closest match.
Frequently Asked Questions
An ideal constraint (what this tool uses) is a preference the browser tries to satisfy but can substitute the closest supported value for. An exact constraint is a hard requirement - if the camera genuinely cannot produce it, the call fails outright with an OverconstrainedError instead of falling back.
track.getCapabilities() isn't implemented consistently across every browser, and some virtual or software-based camera drivers don't expose a capabilities object at all. It's also only available on a live track after permission is granted - there's no way to query it beforehand.
Yes. USB bandwidth limits, sensor binning modes, and driver-specific behavior all vary by device, so identical requested constraints can be negotiated down to different actual resolutions or frame rates depending on the camera.
It counts frames that actually arrived at the video element and were decoded/painted, not raw sensor captures. If a driver or codec drops frames upstream, this tool reports what was actually delivered, which can be lower than the camera's nominal spec.
Many webcams automatically lower their frame rate in dim conditions to lengthen exposure time per frame and keep the image brighter. This is firmware-level behavior on the camera itself, outside the browser's control, and it will show up here as a lower measured FPS even with the same preset requested.