MediaDeviceInfo: label プロパティ

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since September 2017.

MediaDeviceInfo インターフェイスの読み取り専用プロパティ label は、デバイスの説明の文字列 (例:"External USB Webcam") を返します。

活動中の MediaStream の使用中か、永続的な許可を得られているときのみ参照できます。

メディアデバイスを説明する文字列です。セキュリティ上の理由で、1 個以上のメディアデバイスを使用する許可を得られていないときは、label は常に空文字列 ("") です。この許可は、マイクまたはカメラからのストリームを開始するか、永続的な許可を得ることで得られます。

仕様書

Specification
Media Capture and Streams
# dom-mediadeviceinfo-label

ブラウザーの互換性

Report problems with this compatibility data on GitHub
desktopmobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
label

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support