This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 25752 - sourceType is redundant as constraint
Summary: sourceType is redundant as constraint
Status: RESOLVED FIXED
Alias: None
Product: WebRTC Working Group
Classification: Unclassified
Component: Media Capture and Streams (show other bugs)
Version: unspecified
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: public-media-capture@w3.org
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 25769 25775 25778
  Show dependency treegraph
 
Reported: 2014-05-16 22:54 UTC by Shijun Sun
Modified: 2014-08-22 08:56 UTC (History)
3 users (show)

See Also:


Attachments

Description Shijun Sun 2014-05-16 22:54:01 UTC
In the MediaStreamConstraints dictionary, the "video" and "audio" properties already indicate whether the source should be a camera or microphone for the specific MediaTrackConstraints. Having an "sourceType" doesn't give the UA more meaningful instruction, meanwhile, can introduce unnecessary conflict, e.g. by setting the sourceType to "camera" on the "audio" property.

Also, typically we should not expect the sourceType to change while applying new constraints on an existing MediaStreamTrack.  MediaStreamTrack.kind indicates the sourceType already.  There is no clear value keeping the sourceType as constraints in this case either.

sourceType "none" is covered by the MediaStreamTrack.radyState, again redundant.

Suggest removing sourceType from the constraints list, and mapping the concept to other attributes defined in the spec already.
Comment 1 Harald Alvestrand 2014-06-30 13:58:46 UTC
This property was added with the idea that it could be extended - with, for instance, "file", "screencapture" or others.

At the moment, it is not useful. Suggest removing it until we have a real use case for it.
Comment 2 Harald Alvestrand 2014-07-04 11:52:49 UTC
Question sent on the mailing list about removing it on July 4, 2014
Comment 3 Adam Bergkvist 2014-08-22 08:56:16 UTC
Removed sourceType (and SourceTypeEnum)

Proposed fix: https://github.com/w3c/mediacapture-main/commit/71f3030cdd686f84bd6decb895d2196c13092bcd