IMA SDK for HTML5 を使用すると、特定のウェブページに連続再生のコンテキストを設定できます。
呼び出すことができます。「
setContinuousPlayback()
メソッドは、プレーヤーでコンテンツ動画の連続再生をするかどうかを SDK に通知します。
テレビ放送に似ています。true に設定すると、
リクエストは、連続再生に適したものとして広告サーバーによって指定されたリクエストです。×
このメソッドを呼び出す
設定は不明のままです
次のサンプルは、広告リクエストで連続再生を設定する方法を示しています。
var adsRequest =new google.ima.AdsRequest(); adsRequest.adTagUrl(adTagUrl); adsRequest.setContinuousPlayback(true); adsLoader.requestAds(adsRequest);
連続再生と広告の自動再生の違い
IMA SDK for HTML5 では、プレーヤーで再生を開始するかどうかを設定することもできます。
ユーザーの操作が再生が開始されるまで待つかを選択できます。これには
setAdWillAutoPlay()
メソッドを呼び出します。true に設定すると、広告で指定されたものが返されます。
サーバーを自動再生環境に適したものとして選択する必要があります。
[null,null,["最終更新日 2024-10-15 UTC。"],[[["The IMA SDK for HTML5 allows publishers to set the continuous play context for ad requests, signaling whether content videos will play continuously, influencing the ads served."],["The `setContinuousPlayback()` method indicates if videos will autoplay sequentially, similar to a TV broadcast, while `setAdWillAutoPlay()` specifies if ads themselves will autoplay."],["This distinction is crucial as continuous play impacts ad selection from the ad server, ensuring ads suitable for continuous content are delivered, while autoplay dictates ad playback behavior."],["Publishers should align these settings with their content strategy: single videos with user interaction require neither, single autoplaying videos need `setAdWillAutoPlay(true)`, playlists with autoplay after the first video use `setContinuousPlayback(true)`, and fully autoplaying playlists utilize both."]]],[]]