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

Simplify model: Remove "detach source" from descriptions #164

Closed
alvestrand opened this issue Apr 22, 2015 · 1 comment
Closed

Simplify model: Remove "detach source" from descriptions #164

alvestrand opened this issue Apr 22, 2015 · 1 comment
Assignees

Comments

@alvestrand
Copy link
Contributor

Copied from list email, April 15:

In the current specification, we have two concepts related to sources and tracks:

  • A track can be stop()ed, in which case it is ended.
  • A track can be detached from its source.

The text says:

A) in terminology for "source", we have:

Sources are detached from a track when the track is ended for any reason.

B) Under "Life-cycle and Media Flow", we have:

A MediaStreamTrack can be detached from its source. It means that the track is no longer dependent on the source for media data. If no other MediaStreamTrack is using the same source, the source will be stopped. MediaStreamTrack attributes such as kind and label must not change values when the source is detached.

C) Under the "enabled" attribute of a track, we have:

On getting, the attribute must return the value to which it was last set. On setting, it must be set to the new value, regardless of whether the MediaStreamTrack object has been detached from its source or not.

Under the "stop" function for a track, we have:

  1. Set track's readyState attribute to ended.
  2. Detach track's source.

It seems to me that this is one concept more than we need.
Whether there is a relationship between a stopped track and its source or not is an implementation detail, and we shouldn't be constraining it in our API description.

So my suggestion:

In A, C and D, simply remove the text that refers to "Detach".

In B, instead say:

If all MediaStreamTracks that are using the same source are ended, the source will be stopped.

I think that simplifies the terminology, and doesn't change any observable property of the API.

@burnburn
Copy link
Contributor

burnburn commented May 7, 2015

Applied in commit 8a05616

@burnburn burnburn closed this as completed May 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants