前贴式广告期间YouTube的PlayerState是什么? [英] What is the YouTube's PlayerState during pre-roll ad?
问题描述
- -1(未启动)
- 0(已结束)
- 1(播放)
- 2(已暂停)
- 3 (缓冲)
- 5(video cued)。 >
- 玩家正在等待用户交互的CUED。
- 用户点击play
- 插播视频广告开始播放
- onStateChange事件:玩家状态改为:-1 (未定义)
- cueVideoById(cggNqDAtJYU,parseInt(0),默认值);
- onStateChange事件:玩家状态改为:5
-
- onStateChange事件:玩家状态改为:2(已暂停)
- -1 (unstarted)
- 0 (ended)
- 1 (playing)
- 2 (paused)
- 3 (buffering)
- 5 (video cued).
- The player is CUED waiting for user interaction.
- User clicks play
- Pre-roll video ad starts to play
- onStateChange event: Player state changed to: "-1" (undefined)
- cueVideoById(cggNqDAtJYU, parseInt(0), default);
- onStateChange event: Player state changed to: "5" (video cued)
- onStateChange event: Player state changed to: "2" (paused)
当玩家第一次加载视频时,它会播放一个未分离的
(-1)事件。当视频被引导并准备播放时,播放器将
播放视频提示(5)事件。在你的代码中,你可以指定
的整数值,或者你可以使用下面的命名空间
变量之一。
<请考虑这一点:$ b
$ ol
玩家状态在前贴片广告?如何知道广告正在播放?
https://developers.google.com/youtube/youtube_player_demo =noreferrer> https://developers.google.com/youtube/youtube_player_demo所以当广告播放时,视频的状态为PAUSED(2)。此外,播放视频()或pauseVideo()的电话将在预卷过程中无效。
The Flash YouTube API getPlayerState() method has 6 possible values:
The manual reads:
When the player first loads a video, it will broadcast an unstarted (-1) event. When a video is cued and ready to play, the player will broadcast a video cued (5) event. In your code, you can specify the integer values or you can use one of the following namespaced variables.
Consider this:
What state is the player in during the pre-roll ad? How do I know an ad is being played?
I did the legwork for you at https://developers.google.com/youtube/youtube_player_demo
Cuing a video with a preroll and then clicking Play leads to:
So the video's state is PAUSED (2) while the ad is playing. Additionally, calls to playVideo() or pauseVideo() will be no-ops during a preroll.
这篇关于前贴式广告期间YouTube的PlayerState是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!