controller = new CaptureController();
const displayMediaOptions = {
controller,
};
videoElem.srcObject =
await navigator.mediaDevices.getDisplayMedia(displayMediaOptions);Using the Captured Surface Control API / notebook
Using the Captured Surface Control API
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.
controller.increaseZoomLevel();<iframe allow="captured-surface-control" src="/some-other-document.html">
...
</iframe>