Skip to content

Commit

Permalink
v1.9.0+20240122
Browse files Browse the repository at this point in the history
  • Loading branch information
aikw committed Feb 26, 2024
1 parent 810a6ef commit 51b6bbe
Show file tree
Hide file tree
Showing 15 changed files with 958 additions and 163 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.md
Expand Up @@ -200,3 +200,16 @@
- API 変更
- [log イベント](https://api.livestreaming.ricoh/docs/clientsdk-api-external-specification/#%E3%82%A4%E3%83%99%E3%83%B3%E3%83%88)を追加しました。getTailReport や getHeadReport で取得できるログと同等の情報を、逐次的なイベントとしてオブジェクトで取得できるようになります。

## v1.9.0
- API 変更
- [NetworkError](https://api.livestreaming.ricoh/docs/clientsdk-error-specification/#networkerror)に SFU が WebRTC 接続を切断判定した場合のエラー 53004 ConnectionClosedByServer を追加しました
- (SFURoom のみ) SFU とのメディア接続が確立した際に発行する[イベント](https://api.livestreaming.ricoh/docs/clientsdk-api-external-specification/#イベント)である mediaopen を追加しました。[getStats](https://api.livestreaming.ricoh/docs/clientsdk-api-external-specification/#getstats) が実行可能か判断するトリガーや、以降 [53719 ConnectionCreateTimeout](https://api.livestreaming.ricoh/docs/clientsdk-error-specification/#networkerror) が発生しないことの確認などに使用できます
- (β) ある connection から見て自分が送信している映像を受信している対向 connection の有無をイベントで通知するようになりました
- 対向の入室や受信モードなどに応じて有無は変化します
- [updateconnectionsstatus イベント](https://api.livestreaming.ricoh/docs/clientsdk-api-external-specification/#イベント)の video.receiver_existence で判断できるようになります
- (β) [connect の options](https://api.livestreaming.ricoh/docs/clientsdk-api-external-specification/#connect) の iceServersProtocol に"tcp_tls"が指定できるようになりました。TURN の TCP か TLS が自動で選択されるようになります
- SDK 修正
- **破壊的変更予定** changestability イベントを changemediastability イベントに変更しました (mediaopen イベントと合わせるため)。現時点では changestability イベントも引き続き使用できますが、今後廃止予定ですので移行をお願いします
- ログの ICE (WebRTC の接続試行) 関連の情報を強化しました
- Client などイベントを発行するクラスが[EventTarget](https://developer.mozilla.org/ja/docs/Web/API/EventTarget)を継承するようになりました。EventTarget に対応していない古いブラウザ(Safari13 以前など)では動作しないようになります
- P2PRoom への connect 時に対向 connection が退室すると InternalError が発生することがある問題を修正しました
21 changes: 18 additions & 3 deletions demo/demo.js
Expand Up @@ -64,10 +64,11 @@ function createClient() {
client.on("connecting", () => {
console.log(client.getState());
});
client.on("open", ({ access_token_json }) => {
client.on("open", ({ access_token_json, connections_status }) => {
console.log(client.getState());
const connection_id = JSON.parse(access_token_json).connection_id;
console.log("connection_id: ", connection_id);
console.log("connections_status receiver_existence: ", connections_status.video.receiver_existence);
});
client.on("closing", () => {
console.log(client.getState());
Expand All @@ -82,6 +83,9 @@ function createClient() {
console.table(e.detail);
console.log(e.toReportString());
});
client.on("mediaopen", (e) => {
console.log("mediaopen");
});
client.on("addremoteconnection", ({ connection_id, meta }) => {
console.log(`add: ${connection_id}`);
console.log(meta);
Expand Down Expand Up @@ -116,9 +120,15 @@ function createClient() {
console.log(`updatemute: ${connection_id} ${mediaStreamTrack.kind}`);
console.log(mute);
});
client.on("changestability", ({ connection_id, stability }) => {
console.log(`changestability: ${connection_id} ${stability}`);

client.on("updateconnectionsstatus", ({ connections_status }) => {
console.log(`updateconnectionsstatus receiver_existence: ${connections_status.video.receiver_existence}`);
});

client.on("changemediastability", ({ connection_id, stability }) => {
console.log(`changemediastability: ${connection_id} ${stability}`);
});

client.on("addremotetrack", async ({ connection_id, mediaStreamTrack, stream, meta, mute }) => {
console.log(connection_id, mediaStreamTrack, stream, meta, mute);
let $video = $(`#${connection_id}`);
Expand All @@ -136,13 +146,18 @@ function createClient() {
}
await $video.play();
});

client.on("updateremotetrack", ({ connection_id, mediaStreamTrack, stream, meta }) => {
console.log(connection_id, mediaStreamTrack, stream, meta);
});
client.on("log", ({ msg, category, subcategory, date }) => {
// if (type != "stats") console.log(`[${date.toISOString()}]\t"${category}",\t"${subcategory}",\t${msg}`);
});

client.on("log", ({ msg, category, subcategory, date }) => {
// if (type != "stats") console.log(`[${date.toISOString()}]\t"${category}",\t"${subcategory}",\t${msg}`);
});

return client;
}

Expand Down
2 changes: 1 addition & 1 deletion jsdoc/index.html
Expand Up @@ -56,7 +56,7 @@ <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="module-ri
<br class="clear">

<footer>
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Thu Jan 18 2024 23:38:36 GMT+0000 (Coordinated Universal Time)
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Mon Feb 26 2024 23:04:29 GMT+0000 (Coordinated Universal Time)
</footer>

<script> prettyPrint(); </script>
Expand Down
40 changes: 20 additions & 20 deletions jsdoc/module-ricoh-ls-sdk-Client.html
Expand Up @@ -95,7 +95,7 @@ <h4 class="name" id="Client"><span class="type-signature"></span>new Client<span

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1477">line 1477</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1547">line 1547</a>
</li></ul></dd>


Expand Down Expand Up @@ -135,7 +135,7 @@ <h3 class="subsection-title">Extends</h3>


<ul>
<li>ET</li>
<li>EventTarget</li>
</ul>


Expand Down Expand Up @@ -289,7 +289,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2316">line 2316</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2391">line 2391</a>
</li></ul></dd>


Expand Down Expand Up @@ -449,7 +449,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2259">line 2259</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2334">line 2334</a>
</li></ul></dd>


Expand Down Expand Up @@ -586,7 +586,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2392">line 2392</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2467">line 2467</a>
</li></ul></dd>


Expand Down Expand Up @@ -723,7 +723,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2355">line 2355</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2430">line 2430</a>
</li></ul></dd>


Expand Down Expand Up @@ -906,7 +906,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2031">line 2031</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2106">line 2106</a>
</li></ul></dd>


Expand Down Expand Up @@ -995,7 +995,7 @@ <h4 class="name" id="disconnect"><span class="type-signature"></span>disconnect<

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2049">line 2049</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2124">line 2124</a>
</li></ul></dd>


Expand Down Expand Up @@ -1083,7 +1083,7 @@ <h4 class="name" id="getHeadReport"><span class="type-signature"></span>getHeadR

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1844">line 1844</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1918">line 1918</a>
</li></ul></dd>


Expand Down Expand Up @@ -1189,7 +1189,7 @@ <h4 class="name" id="getState"><span class="type-signature"></span>getState<span

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1801">line 1801</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1875">line 1875</a>
</li></ul></dd>


Expand Down Expand Up @@ -1356,7 +1356,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1828">line 1828</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1902">line 1902</a>
</li></ul></dd>


Expand Down Expand Up @@ -1462,7 +1462,7 @@ <h4 class="name" id="getStatsReport"><span class="type-signature"></span>getStat

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1908">line 1908</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1982">line 1982</a>
</li></ul></dd>


Expand Down Expand Up @@ -1568,7 +1568,7 @@ <h4 class="name" id="getTailReport"><span class="type-signature"></span>getTailR

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1876">line 1876</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1950">line 1950</a>
</li></ul></dd>


Expand Down Expand Up @@ -1674,7 +1674,7 @@ <h4 class="name" id="getTrackReport"><span class="type-signature"></span>getTrac

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1925">line 1925</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1999">line 1999</a>
</li></ul></dd>


Expand Down Expand Up @@ -1825,7 +1825,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line3046">line 3046</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line3138">line 3138</a>
</li></ul></dd>


Expand Down Expand Up @@ -2004,7 +2004,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1716">line 1716</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1790">line 1790</a>
</li></ul></dd>


Expand Down Expand Up @@ -2164,7 +2164,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2196">line 2196</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2271">line 2271</a>
</li></ul></dd>


Expand Down Expand Up @@ -2301,7 +2301,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2110">line 2110</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2185">line 2185</a>
</li></ul></dd>


Expand Down Expand Up @@ -2503,7 +2503,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2155">line 2155</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line2230">line 2230</a>
</li></ul></dd>


Expand Down Expand Up @@ -2555,7 +2555,7 @@ <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="module-ri
<br class="clear">

<footer>
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Thu Jan 18 2024 23:38:36 GMT+0000 (Coordinated Universal Time)
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Mon Feb 26 2024 23:04:29 GMT+0000 (Coordinated Universal Time)
</footer>

<script> prettyPrint(); </script>
Expand Down
12 changes: 6 additions & 6 deletions jsdoc/module-ricoh-ls-sdk-ET.html
Expand Up @@ -95,7 +95,7 @@ <h4 class="name" id="ET"><span class="type-signature"></span>new ET<span class="

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line465">line 465</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line486">line 486</a>
</li></ul></dd>


Expand Down Expand Up @@ -195,7 +195,7 @@ <h5>Type:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line477">line 477</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line498">line 498</a>
</li></ul></dd>


Expand Down Expand Up @@ -366,7 +366,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line485">line 485</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line506">line 506</a>
</li></ul></dd>


Expand Down Expand Up @@ -499,7 +499,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line494">line 494</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line515">line 515</a>
</li></ul></dd>


Expand Down Expand Up @@ -678,7 +678,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line509">line 509</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line530">line 530</a>
</li></ul></dd>


Expand Down Expand Up @@ -730,7 +730,7 @@ <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="module-ri
<br class="clear">

<footer>
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Thu Jan 18 2024 23:38:36 GMT+0000 (Coordinated Universal Time)
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Mon Feb 26 2024 23:04:29 GMT+0000 (Coordinated Universal Time)
</footer>

<script> prettyPrint(); </script>
Expand Down
10 changes: 5 additions & 5 deletions jsdoc/module-ricoh-ls-sdk-ErrorData.html
Expand Up @@ -201,7 +201,7 @@ <h5>Parameters:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1322">line 1322</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1392">line 1392</a>
</li></ul></dd>


Expand Down Expand Up @@ -301,7 +301,7 @@ <h5>Type:</h5>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1333">line 1333</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1403">line 1403</a>
</li></ul></dd>


Expand Down Expand Up @@ -381,7 +381,7 @@ <h4 class="name" id="getDetail"><span class="type-signature"></span>getDetail<sp

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1365">line 1365</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1435">line 1435</a>
</li></ul></dd>


Expand Down Expand Up @@ -491,7 +491,7 @@ <h4 class="name" id="toReportString"><span class="type-signature"></span>toRepor

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1379">line 1379</a>
<a href="ricoh-ls-sdk.js.html">ricoh-ls-sdk.js</a>, <a href="ricoh-ls-sdk.js.html#line1449">line 1449</a>
</li></ul></dd>


Expand Down Expand Up @@ -561,7 +561,7 @@ <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="module-ri
<br class="clear">

<footer>
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Thu Jan 18 2024 23:38:36 GMT+0000 (Coordinated Universal Time)
Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.6</a> on Mon Feb 26 2024 23:04:29 GMT+0000 (Coordinated Universal Time)
</footer>

<script> prettyPrint(); </script>
Expand Down

0 comments on commit 51b6bbe

Please sign in to comment.