Yahoo Web Search

Search results

  1. A single MediaStream object can be attached to multiple different outputs at the same time. A new MediaStream object can be created from existing media streams or tracks using the MediaStream() constructor.

  2. Feb 22, 2016 · This document defines APIs for requesting access to local multimedia devices, such as microphones or video cameras. This document also defines the MediaStream API, which provides the means to control where multimedia stream data is consumed, and provides some control over the devices that produce the media.

    • Mediastream III1
    • Mediastream III2
    • Mediastream III3
    • Mediastream III4
    • Overview
    • Concepts and usage
    • Interfaces
    • Guides and tutorials
    • Browser compatibility
    • See also

    The Media Capture and Streams API, often called the Media Streams API or MediaStream API, is an API related to WebRTC which provides support for streaming audio and video data.

    It provides the interfaces and methods for working with the streams and their constituent tracks, the constraints associated with data formats, the success and error callbacks when using the data asynchronously, and the events that are fired during the process.

    The API is based on the manipulation of a MediaStream object representing a flux of audio- or video-related data. See an example in Get the media stream.

    A MediaStream consists of zero or more MediaStreamTrack objects, representing various audio or video tracks. Each MediaStreamTrack may have one or more channels. The channel represents the smallest unit of a media stream, such as an audio signal associated with a given speaker, like left or right in a stereo audio track.

    MediaStream objects have a single input and a single output. A MediaStream object generated by getUserMedia() is called local, and has as its source input one of the user's cameras or microphones. A non-local MediaStream may be representing a media element, like or , a stream originating over the network, and obtained via the WebRTC RTCPeerConnection API, or a stream created using the Web Audio API MediaStreamAudioDestinationNode.

    The output of the MediaStream object is linked to a consumer. It can be a media element, like or , the WebRTC RTCPeerConnection API or a Web Audio API MediaStreamAudioSourceNode.

    In these reference articles, you'll find the fundamental information you'll need to know about each of the interfaces that make up the Media Capture and Streams API.

    •CanvasCaptureMediaStreamTrack

    •InputDeviceInfo

    •MediaDeviceInfo

    •MediaDevices

    •MediaStream

    The Capabilities, constraints, and settings article discusses the concepts of constraints and capabilities, as well as media settings, and includes a Constraint Exerciser that lets you experiment with the results of different constraint sets being applied to the audio and video tracks coming from the computer's A/V input devices (such as its webcam and microphone).

    The Taking still photos with getUserMedia() article shows how to use getUserMedia() to access the camera on a computer or mobile phone with getUserMedia() support and take a photo with it.

    api.MediaStream

    BCD tables only load in the browser with JavaScript enabled. Enable JavaScript to view data.

    api.MediaStreamTrack

    BCD tables only load in the browser with JavaScript enabled. Enable JavaScript to view data.

    api.MediaDevices

    BCD tables only load in the browser with JavaScript enabled. Enable JavaScript to view data.

    •WebRTC - the introductory page to the API

    •Taking still photos with WebRTC: a demonstration and tutorial about using getUserMedia().

  3. Sep 8, 2022 · Step 1: Generate the tracks. const userMedia = await navigator.mediaDevices.getUserMedia({audio : true, video : true}); const videoTrack = userMedia.getVideoTracks()[0]; const audioTrack = userMedia.getAudioTracks()[0]; Step 2: Create a MediaStream and add tracks to them. const stream = new MediaStream(); stream.addTrack(videoTrack);

  4. Dec 21, 2023 · The MediaStream interface of the Media Capture and Streams API represents a stream of media content. A stream consists of several tracks, such as video or audio tracks.

  5. May 31, 2012 · In this spec, references to MediaStream s and MediaInput s refer to the DOM-visible state, and references to media streams and input ports refer to the underlying real-time media stream graph. A stream is an abstraction of a time-varying video and/or audio signal.

  6. Aug 12, 2015 · Introduction. This section is non-normative. MediaStream objects act as opaque handles to a stream of audio and video data. These can be consumed in a variety of ways by various platform APIs, as discussed in [GETUSERMEDIA].