blob: bedccb5eb0239162c91e08bccbb2b11bf9232c51 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
---
title: Navigator.activeVRDisplays
slug: Web/API/Navigator/activeVRDisplays
tags:
- API
- Experimental
- HTML DOM
- Navigator
- Property
- Reference
- VR
- Virtual Reality
- WebVR
- activeVRDisplays
translation_of: Web/API/Navigator/activeVRDisplays
---
<div>{{DefaultAPISidebar("WebVR API")}}{{Obsolete_header}}</div>
<p><strong><code>activeVRDisplays</code></strong> は {{domxref("Navigator")}} インターフェイスの読み取り専用プロパティで、現在表示中 ({{domxref("VRDisplay.ispresenting")}} が <code>true</code>) のすべての {{domxref("VRDisplay")}} オブジェクトを含んだ配列を返します。</p>
<h2 id="Syntax" name="Syntax">構文</h2>
<pre class="syntaxbox notranslate">var myActiveDisplays = navigator.activeVRDisplays;</pre>
<h3 id="Value" name="Value">値</h3>
<p>{{domxref("VRDisplay")}} オブジェクトの配列です。</p>
<h2 id="Examples" name="Examples">例</h2>
<pre class="brush: js notranslate">function showActive() {
var displays = navigator.activeVRDisplays;
for(var i = 0; i < displays.length; i++) {
console.log('Display ' + displays[i].displayId + ' is active.');
}
}
</pre>
<h2 id="Specifications" name="Specifications">仕様書</h2>
<table class="standard-table">
<thead>
<tr>
<th scope="col">仕様書</th>
<th scope="col">状態</th>
<th scope="col">備考</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{SpecName("WebVR 1.1", '#navigator-activevrdisplays-attribute', 'activeVRDisplays')}}</td>
<td>{{Spec2("WebVR 1.1")}}</td>
<td>初回定義</td>
</tr>
</tbody>
</table>
<h2 id="Browser_compatibility" name="Browser_compatibility">ブラウザーの互換性</h2>
<p>{{Compat("api.Navigator.activeVRDisplays")}}</p>
<h2 id="参照">参照</h2>
<ul>
<li><a href="/ja/docs/Web/API/WebVR_API">WebVR API ホームページ</a></li>
<li><a href="http://mozvr.com/">MozVr.com</a> — Mozilla VR チームのデモ、ダウンロード、その他のリソース</li>
</ul>
|