Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playback and synchronization of MediaStreamTracks created by VideoTrack Generator #86

Open
aboba opened this issue Oct 4, 2022 · 4 comments
Assignees

Comments

@aboba
Copy link
Contributor

aboba commented Oct 4, 2022

VideoTrackGenerator (the successor to MSTG) converts a stream of VideoFrames to a MediaStreamTrack.

VideoFrames may have been "transformed" by a process that generates jitter. For example, they may have been processed by a Machine Learning algorithm that takes a varying amount of time, or they may have been produced by a decoder that received encoded chunks over a network with varying delays.

Currently, the specification does not talk about what an application can expect of VideoTrackGenerator in terms of playout delay and rendering smoothness. Does VideoTrackGenerator assume that there is a jitter buffer upstream that generates VideoFrames with constant delays? Or does VideoTrackGenerator adjust the playout delay in response to the jitter it experiences in the VideoFrames it receives?

@aboba aboba changed the title Applicability of VideoTrackGenerator? Effect of Jitter on VideoTrackGenerator Oct 4, 2022
@tonyherre
Copy link

Should the VideoFrame's timestamp relate to this as well? The webcodecs spec defines it as "The presentation timestamp", with a note about potentially using it to guide rate control in the encoder.
It would be great if we could specify its behaviour in the context of mediacapture transforms.

@alvestrand
Copy link
Contributor

I think the timestamps in the stream coming from VTG are the timestamps coming into the VTG - dejittering should happen just before playback (or other process that needs a regular cadence).

Needs discussion.

@aboba aboba changed the title Effect of Jitter on VideoTrackGenerator Playback and synchronization of MediaStreamTracks created by VideoTrack Generator Sep 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants