問題描述
我知道 Google Chrome 有一項自動播放政策,即無法自動播放帶音頻的視頻.像 YouTube 和 Twich 這樣的網站怎么能繞過這個?他們如何自動播放帶音頻的視頻?
I know that Google Chrome has an autoplay policy where videos with audio cannot be autoplayed. How come websites like YouTube and Twich are able to bypass this? How can they autoplay videos with audio?
推薦答案
看起來他們被特別列入白名單.
It looks like they're specially white-listed.
Chrome 通過了解您的偏好來做到這一點.如果你沒有瀏覽歷史記錄,Chrome 允許自動播放超過 1,000 個網站看到最高比例的訪問者播放有聲媒體.作為您瀏覽網絡時,該列表會隨著 Chrome 的學習和啟用而改變在您大部分時間播放有聲媒體的網站上自動播放訪問,并在您不訪問的網站上禁用它.這樣,Chrome為您提供個性化、可預測的瀏覽體驗.
Chrome does this by learning your preferences. If you don’t have browsing history, Chrome allows autoplay for over 1,000 sites where we see that the highest percentage of visitors play media with sound. As you browse the web, that list changes as Chrome learns and enables autoplay on sites where you play media with sound during most of your visits, and disables it on sites where you don’t. This way, Chrome gives you a personalized, predictable browsing experience.
來源:https://blog.google/products/chrome/improving-autoplay-chrome/
這篇關于YouTube 和 Twitch 如何覆蓋帶音頻視頻的自動播放策略?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!