marp | theme | paginate | backgroundColor | footer |
---|---|---|---|---|
true |
default |
true |
![width:50px](gfx/w3c.png) Second Screen WG/CG virtual meeting |
A Collection of Interesting Ideas
<style> table, th, tr, td { border: 0px !important; border-collapse: collapse !important; border:none !important; outline:none !important; } </style>
<iframe width="533" height="300" src="https://www.youtube-nocookie.com/embed/rmg5tZ4iSx8?start=34" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe> | <iframe width="533" height="300" src="https://www.youtube-nocookie.com/embed/IbN9f8uNT2M?start=182" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe> |
"a display instance without a physical connection to the graphics card"
"a software representation of a physical display"
- 1️⃣ 🚧 Display Arrangement
- ➡️ OS
- 2️⃣ ✅ Display Source Picker
- 3️⃣ 🚧 Virtual Display Creation
- ➡️ OS
- 4️⃣ ✅ Window Placement
- ➡️ OS
- ➡️ Multi-Screen Window Placement API?
- (Virtual workspaces/desktops a non-goal, how about Virtual Displays?)
(Chrome display source picker UI, https://www.webrtc-experiment.com/getDisplayMedia/)
(Deskreen Virtual Display Picker UI, https://deskreen.com/)
2️⃣ getDisplayMedia
UI vs 3️⃣ Deskreen Virtual Display UI
-
Keyboard shortcuts in Windows: "Windows logo key + Shift + Left arrow or Right arrow to move an app or window in the desktop from one monitor to another."
-
Drag and drop evolved in macOS: "Drag the app window you want to move to the edge of the screen [or] enter Mission Control, then drag the window up to the space you want to use."
Could such implicit permission grants work for web app window placement?
How? Set a strong privacy baseline & leave room for Quality of Implementation differentiation?
- "Let me create a new virtual display surface & place windows on it, get its relative positioning and a representation I can pass on to other Web APIs."
MediaStream
as the "common currency" forgetDisplayMedia
& WebRTC interop- Reuse existing API constructs and browser and OS UI/UX
- Agnostic with regard to the display technology
- Meet security and privacy expectations
- Web users expect multi-screen use cases to work similarly with Virtual Displays
- Web APIs shouldn't(?) fully abstract away virtual/physical display boundary
- A new virtual display surface type that maps to an OS-level concept
- Allow {extending|mirroring} of {monitor|window|browser} display surface to a virtual display surface
- User-initiated and programmatic window placement
- Use platform-native UX concepts (e.g. drag/move windows across, share controls)
- Present a new document (Presentation API) or video element (Remote Playback API)
- Share controls across devices: Synergy/Barrier, Logitech Flow, Universal Control
- Admin/advanced: various Remote desktop software, PowerToys FancyZones layouts
"Sometimes I want to use the display of my tablet along with my primary device's display and let web apps make use of both. I want to be able to control what web content to present on my tablet."
"Sometimes when lounging in the living room I want to extend my workspace to the TV. I want to stay in control of what web content to share on the TV to a larger audience."
- Deskreen mirrors a virtual display (created with BetterDummy) to a browser window on a tablet
- WebRTC MediaStream
- Same LAN
See also: session initiation sequence diagram
- Deskreen mirrors a virtual display (created with BetterDummy) to an offscreen browser window
- Presentation API mirrors that offscreen browser window to a TV connected to a Chromecast (1-UA mode triggered via browser UI)
- WebRTC MediaStream ➡️ Cast Mirroring
- Chromecast in same LAN
- Windows "multiple desktops" / VirtualDesktopManager
- macOS "spaces" / no public API
- Chrome OS "virtual desks" / Wayland API issues
- Virtual screen arrangement readable via
getScreenDetails()
- ✅
getDisplayMedia()
satisfies "display surface toMediaStream
" req / screen mirroring/sharing use case - 🚧 Virtual display surface type
- 🚧 Picker UI for virtual displays (create a new?)
getDisplayMedia extension ideas (reusable for picking multiple virtual displays?):
- getDisplayMedia issue #204: Concurrent capture of multiple surfaces
- Capture multiple surfaces w/ getDisplayMedia proposal
- Windows: user-mode indirect display driver model
- macOS: 3rd party tools e.g. BetterDummy
- Linux: e.g. GNOME headless native backend in Mutter
- Generic: physical Dummy Display Plugs, various Virtual Display drivers
- Virtual Display concept does not exists
- Interesting parallels: Audio Output Devices API to allow routing audio to a "virtual" (other than the default) audio sink, see also new sink available
- display surface and its
DisplayCaptureSurfaceType
CursorCaptureConstraint
- virtual screen arrangement,
isExtended
,getScreenDetails()
getDisplayMedia
extensions
- Picker UI extended to allow a new Virtual Display creation
- Extend
DisplayCaptureSurfaceType
enum withvirtual
- Reuse existing signaling of closed/minimized display surfaces
- ...
partial interface MediaDevices {
Promise<MediaStream> getDisplayMedia(optional DisplayMediaStreamConstraints constraints = {});
};
enum DisplayCaptureSurfaceType {
"monitor",
"window",
"browser",
"virtual" // new
};
- Redundant if
getDisplayMedia
extensions satisfy reqs
- Presentation API Presentation of objects proposal incl.
MediaStream
- Site Initiated Mirroring API
- getDisplayMedia extension: "no API that allows a MediaStream to be sent directly to a secondary display (without going through WebRTC)."
- Remote Playback API via
HTMLMediaElement.srcObject = ms
too much indirection
- 1️⃣ Explainer 🔗
-
Use cases, reqs, API sketch, considered alternatives
📍We are here!
-
- 2️⃣ Explainer review
-
Web community, browser & OS vendors, hardware ecosystem
-
- 3️⃣ Draft web spec
-
W3C Second Screen CG in collaboration with WebRTC WG?
-
- 4️⃣ 🧪 Prototype in code
-
Example: Chromium launch process
-
- 5️⃣ 📢 Prototype feedback
-
Web developer feedback can change the shape of the API significantly
-
- 6️⃣ Standards track
-
Subject to support, possible WG adoption
-