1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/dom/webidl/MediaStream.webidl Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,35 @@ 1.4 +/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this file, 1.7 + * You can obtain one at http://mozilla.org/MPL/2.0/. 1.8 + * 1.9 + * The origins of this IDL file are 1.10 + * http://dev.w3.org/2011/webrtc/editor/getusermedia.html 1.11 + * 1.12 + * Copyright � 2012 W3C� (MIT, ERCIM, Keio), All Rights Reserved. W3C 1.13 + * liability, trademark and document use rules apply. 1.14 + */ 1.15 + 1.16 +// These dictionaries need to be in a separate file from their 1.17 +// MediaTrackConstraints* counterparts due to a webidl compiler limitation. 1.18 + 1.19 +dictionary MediaStreamConstraints { 1.20 + (boolean or MediaTrackConstraints) audio = false; 1.21 + (boolean or MediaTrackConstraints) video = false; 1.22 + boolean picture = false; // Mozilla legacy 1.23 + boolean fake = false; // for testing 1.24 +}; 1.25 + 1.26 +interface MediaStream { 1.27 + // readonly attribute DOMString id; 1.28 + sequence<AudioStreamTrack> getAudioTracks (); 1.29 + sequence<VideoStreamTrack> getVideoTracks (); 1.30 + // MediaStreamTrack getTrackById (DOMString trackId); 1.31 + // void addTrack (MediaStreamTrack track); 1.32 + // void removeTrack (MediaStreamTrack track); 1.33 + // attribute boolean ended; 1.34 + // attribute EventHandler onended; 1.35 + // attribute EventHandler onaddtrack; 1.36 + // attribute EventHandler onremovetrack; 1.37 + readonly attribute double currentTime; 1.38 +};