- From: Jan-Ivar Bruaroey via GitHub <sysbot+gh@w3.org>
- Date: Tue, 10 Dec 2024 00:11:31 +0000
- To: public-webrtc-logs@w3.org
> If a callback is really desired, a compromise would be the following: > > * enqueue a task on each track to fire `configurationchange` on each track task queue with MediaStreamTrack task source > > * enqueue a task to execute the callback on capture controller task queue with MediaStreamTrack task source > > > I don't think the added delay of executing a few tasks will change much in practice Are you merely proposing an order in which tasks are queued? If so, what _"added delay of executing"_ are you referring to? > As of the second guarantee, it is only useful for asynchronous pausing. My understanding is both guarantees are needed to prevent frames resuming in the background media thread here: ```js let {deviceId} = track.getSettings(); track.onconfigurationchange = e => { if (deviceId != track.getSettings().deviceId) { deviceId = track.getSettings().deviceId; track.enabled = false; } } ``` IOW, the UA MUST take JS state on callback return into account when deciding to resume frames in the background thread. I.e. it must block frames on main thread. >... I am really hesitant to expose a persistent no-video-frame state that is not muted. It's not a state as far as the web developer is concerned, merely a delay function. At least no more than a transform is a state. > Please also note that the use cases are all about pausing the sending of video frames to specific track sinks, not to pause the source. Conceptually, a callback on CaptureController (which represents the source) is misaligned with the presented use cases. The cause is at the source. Conceptually, it seems simpler for web developers to gate frames from a switch at the source. -- GitHub Notification of comment by jan-ivar Please view or discuss this issue at https://github.com/w3c/mediacapture-screen-share-extensions/issues/15#issuecomment-2529889684 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Tuesday, 10 December 2024 00:11:32 UTC