排版引擎比較 (HTML5媒體)

本頁使用了標題或全文手工轉換
維基百科,自由的百科全書

HTML5規範定義了幾個標籤,允許在語義上原生包含視頻和音頻。下表比較了排版引擎之間對這一規範各個方面的支持。

表格說明

引擎命名

這裡使用後端的引擎名而不是瀏覽器的名稱。使用各瀏覽器引擎的瀏覽器如下表所示。

排版引擎 發行版本 預覽版本 使用
Amaya 11.4.7[1] 不適用 停止開發;Amaya
Blink 537.36 原始碼[注 1] Chromium/Chrome(28+)、Opera(15+)、YandexMicrosoft Edge(新版)
EdgeHTML 13.10586 [2] 不適用 Microsoft Edge(舊版)、通用Windows平台 (UWP)JavaScript應用
Gecko
標準版77.0.1(2018年8月8日,​5年前​(2018-08-08[3]
延長支持版(ESR)68.9.0(2018年6月26日,​5年前​(2018-06-26[4]


Beta及開發者版126.0b5[5]在維基數據編輯(2024年4月24日)
Nightly127.0a1[6]在維基數據編輯(2024年4月15日)
所有Mozilla軟體,包括FirefoxSeaMonkeyGaleonCaminoK-MeleonFlock(至2.x版本);Debian IceWeaselGNU IceCat(前身為GNU IceWeasel);CyberfoxIcedoveIceapeIceowlFirefox for mobile("Fennec")
KHTML 4.12.3[7] 不適用 Konqueror[注 2]
Presto 2.12.388 不適用 停止開發;OperaOpera Mobile現在使用Blink;任天堂DS & DSi瀏覽器Internet Channel
Tasman (Mac版IE 5.2.3) 不適用 2003年停止開發;Mac OS XInternet Explorer 5以上
Trident 7.0(IE 11) 不適用 Internet Explorer與其他Internet Explorer shellMaxthon(僅限Microsoft Windows作業系統)、Windows Phone 8
WebKit 534.20 每日構建[注 3] Tizen(OS與瀏覽器)、Safari(桌面與移動版)、Google Chrome(28版本之前)、Maxthon 3Shiira, iCab 4OmniWeb 5.5+、WebAdobe AIRMidori, Adobe Dreamweaver CS4CS5Android瀏覽器、Palm webOS瀏覽器、Symbian S60瀏覽器、OWB英語Origyn Web BrowserSteamRekonqAroraFlock (版本3以上)、RockMelt海豚瀏覽器SleipnirKonqueror[注 2]
  1. ^ chromium / chromium/blink. chromium.googlesource.com. Google. [2014-05-27]. 
  2. ^ 2.0 2.1 在Konqueror中,用戶可以切換排版引擎。
  3. ^ WebKit Nightly Builds. webkit.org. [2014-05-27]. 


取值

以下各格的顏色表示該排版引擎的最新版本或指定版本(如果給出版本號的話)對該功能的支援程度。沒有取值的版本號表示該排版引擎首次完全支援該功能。

取值 含義
表示該排版引擎完全地支援該功能或元素。
表示該功能或元素尚未有支援。
部份 表示該功能或元素有實作進展,但並不支援所有取值,對於已支援的取值,該實作是正確的。
不正確 表示該功能或元素有實作進展,但是實作並非在所有情況都是正確無誤的。
實驗性質 表示該功能或元素有實作進展,但是使用另外的屬性或元素名(瀏覽器前輟)。多半是不完全實作或是有過多的漏洞
拋棄 表示該屬性/元素不再受到支援。
每日構建 表示該功能或元素在未釋出的版本有某種程度的支援。預期將有完整支援。
依情況 表示該屬性/元素僅在某些平台支援或設定在某些組態後支援。

元素屬性

媒體元素允許在標籤中直接設定某些屬性

Trident Gecko WebKit Presto
<audio>屬性
src 5.0[t 1] 1.9.1 525 2.5
preload 2.0[note 1][g 1] 實驗性質[note 1]
autoplay 1.9.1 2.5
loop 11.0[g 2]
controls 1.9.1
<video>屬性
src 5.0[t 1] 1.9.1 525 2.5
preload 2.0[note 1][g 1] 實驗性質[note 1]
autoplay 1.9.1 2.5
loop 11.0[g 2]
controls 1.9.1
poster 1.9.2[g 3]
width 1.9.1
height
<source>屬性
src 5.0[t 1] 1.9.1 525[w 1] 2.5
type
media 15.0[g 4]
<track>屬性
kind 6.0[t 2] 24.0[g 5] [w 2]
label
src
srclang

DOM屬性

與媒體元素有關的一些屬性包含在DOM中。

Trident Gecko WebKit Presto[p 1]
錯誤狀態
MediaError 5.0 [t 3] 1.9.1 ? 2.5
網路狀態
src 5.0[t 1] 1.9.1 ? 2.5
currentSrc
networkState
preload 2.0[note 1][g 1]
buffered 2.0[g 6]
load() 1.9.1 2.5
canPlayType() 533[w 3]
就緒狀態
readyState 5.0[t 1] 1.9.1 ? 2.5
seeking
回放狀態
currentTime 5.0[t 1] 1.9.1 ? 2.5
startTime
duration 1.9.1
paused
defaultPlaybackRate 20.0[g 7]
playbackRate
played 15.0[g 8]
seekable 8.0[g 9]
ended 1.9.1 2.5
autoplay
loop 11.0[g 2]
play() 1.9.1
pause()
控制
controls 5.0[t 1] 1.9.1 ? 2.5
volume
muted

DOM事件

媒體元素引入新的事件處理僅適用於那些元素的情況,如暫停/恢復。

Trident Gecko[g 10] WebKit Presto
loadstart 5.0[t 4] 1.9.1 ? ?
progress
suspend 1.9.2
abort 1.9.1
error
emptied
stalled 8.0[g 11]
play 1.9.1
pause
loadedmetadata
loadeddata
waiting
playing
canplay 1.9.1
canplaythrough
seeking
seeked
timeupdate
ended
ratechange
durationchange
volumechange

影片格式支援

Trident Gecko WebKit Presto
Ogg Theora 手動安裝[note 2] 1.9.1[g 12] 依情況[note 3] 2.5
H.264 5.0[t 6] 33.0[8][g 13] 依賴(525)[note 3][w 9] 依情況[note 4]
WebM VP8 手動安裝[note 2] 2.0[g 14][g 15] 依賴(534)[w 10] 2.6.30[p 3][p 4][p 5]

音訊格式支援

Trident Gecko WebKit Presto
Ogg Vorbis 手動安裝[note 2] 1.9.1[g 12] 依情況[note 3] 2.5
WAV PCM 525[note 3] 2.0
MP3 5.0[t 7] [g 16] 依情況[note 4]
AAC
Speex 手動安裝[note 2] [g 17] 依情況[note 3]
Opus IE 12 ?? [g 18] 15.0[g 19] 依情況[note 3]

注釋

  1. ^ 1.0 1.1 1.2 1.3 1.4 preload以舊名字autobuffer支援。
  2. ^ 2.0 2.1 2.2 2.3 Google為多媒體應用庫發布了一個WebM組件以允許WebM檔案在IE9中通過標準HTML5<video>標籤播放[t 5]Xiph.org分發了OpenCodecs包,其修正了Google的基於DirectShow的VP8解碼器。VLC多媒體播放器附帶有「網頁外掛程式」,從而使VLC從<video><audio>標籤中播放多媒體,讓其支援所有VLC支援的格式。
  3. ^ 3.0 3.1 3.2 3.3 3.4 3.5 在Mac OS X下WebKit支援QuickTime[w 4],預設情況下,其支援H.264、MP3、AAC和WAV PCM格式,如果安裝了XiphQT等第三方編解碼器則會額外支援Ogg Theora與Vorbis格式。Google Chrome支援Theora、Vorbis、WebM與MP3格式[w 5]。Chromium可以被編譯以支援任意FFmpeg支援的格式,並可以選擇是否支援諸如H.264和MP3的專利格式[w 6]MorphOS上的Origyn網頁瀏覽器也採用FFmpeg播放HTML5媒體內容。[w 7][w 8]
  4. ^ 4.0 4.1 在Linux與FreeBSD上,Presto 2.5使用GStreamer庫的系統版本,並且可以播放任何GStreamer支援的格式(包括H.264、MP3、AAC等, 前提是已安裝解碼器) 。在其他平台上,它只支援Ogg Theora格式的影片和Ogg Vorbis與WAVE PCM的音訊。[p 2]

參考

  1. ^ Amaya Binary Releases, Most recent download link in stable
  2. ^ Change log between EdgeHTML 12.10240 and 13.10586
  3. ^ Firefox 77.0.1, See All New Features, Updates and Fixes. mozilla.org. Mozilla基金會. 2020-06-03. 
  4. ^ Firefox ESR 68.9.0, See All New Features, Updates and Fixes. mozilla.org. Mozilla基金會. 2020-06-02. 
  5. ^ Index of /pub/firefox/releases/126.0b5/. 2024年4月24日 [2024年4月25日] (英語). 
  6. ^ Firefox Nightly 127.0a1, See All New Features, Updates and Fixes. 2024年4月15日 [2024年4月16日] (英語). 
  7. ^ Download for kdelibs, Most recent download link in stable
  8. ^ via OpenH264

Trident參考

  1. ^ 1.0 1.1 1.2 1.3 1.4 1.5 1.6 Internet Explorer Platform Preview Guide for Developers, Microsoft, [2016-02-06], (原始內容存檔於2014-03-12) 
  2. ^ track element - track object (Internet Explorer). Microsoft. [12 July 2013]. (原始內容存檔於2013-07-15). 
  3. ^ MSDN HTMLMediaError Object for Internet Explorer 9, Microsoft, [2016-02-06], (原始內容存檔於2017-05-28) 
  4. ^ video object. Microsoft. [12 July 2013]. (原始內容存檔於2016-03-14). 
  5. ^ Jazayeri, Mike, More about the Chrome HTML Video Codec Change, Google, 2011-01-14 [2016-02-06], (原始內容存檔於2012-10-03) 
  6. ^ McCracken, Harry, Microsoft Previews the Revamped Internet Explorer 9 Platform, Technologizer, 2010-03-16 [2016-02-06], (原始內容存檔於2021-02-28) 
  7. ^ Branscombe, Mary, Microsoft previews Internet Explorer 9, TechRadar UK, 2010-03-16, (原始內容存檔於2010-03-22) 

Gecko參考

  1. ^ 1.0 1.1 1.2 Bug 548523 - HTML 5 media attribute 'autobuffer' has been renamed to 'preload', Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  2. ^ 2.0 2.1 2.2 Bug 449157 - Implement the looping attributes in media elements, Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  3. ^ Bug 449156 - Implement the poster attribute for the <video> element, Mozilla, [2016-02-06], (原始內容存檔於2021-01-24) 
  4. ^ Bug 449363 - Support media attribute of <source> elements, Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  5. ^ Bug 629350 - Implement the track element, Mozilla, [2016-02-06], (原始內容存檔於2019-04-02) 
  6. ^ Bug 462957 - Implement nsIDOMHTMLMediaElement::GetBuffered(), Mozilla, [2016-02-06], (原始內容存檔於2021-03-07) 
  7. ^ Bug 495040 - Implement playbackRate, Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  8. ^ Bug 462959 - Implement nsIDOMHTMLMediaElement::GetPlayed(), Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  9. ^ Bug 462960 - Implement nsIDOMHTMLMediaElement::GetSeekable(), Mozilla, [2016-02-06], (原始內容存檔於2021-03-07) 
  10. ^ Using audio and video in Firefox - Media events, Mozilla, [2016-02-06], (原始內容存檔於2012-05-08) 
  11. ^ Bug 481082 - Video controls should listen for |stalled| event, Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  12. ^ 12.0 12.1 Shepherd, Eric, Media formats supported by the audio and video elements, Mozilla, 2010-01-28 [2009-10-11], (原始內容存檔於2012年5月4日) 
  13. ^ Bug 799318 - [meta] Support H.264/AAC/MP3 video/audio playback on desktop Firefox, Mozilla, [2016-02-06], (原始內容存檔於2021-02-24) 
  14. ^ Bug 566243 - Merge mozilla-webmedia repository to mozilla-central, Mozilla, [2016-02-06], (原始內容存檔於2021-02-24) 
  15. ^ Firefox WebM Builds, Mozilla, [2016-02-06], (原始內容存檔於2010-06-08) 
  16. ^ Bug 562730 - Reproducing Mp3 files with html5, Mozilla, [2016-02-06], (原始內容存檔於2021-03-07) 
  17. ^ Bug 476752 - support the speex voice codec in <audio> and <video> elements, Mozilla, [2016-02-06], (原始內容存檔於2021-03-08) 
  18. ^ Bringing Interoperable Real-Time Communications to the Web, Skype, [2016-02-06], (原始內容存檔於2016-08-09) 
  19. ^ Bug 674225 - support the Opus voice codec in <audio> and <video> elements, Mozilla, [2016-02-06], (原始內容存檔於2020-11-11) 

WebKit參考

  1. ^ Pfeiffer, Silvia, [whatwg] Quality Values for Media Source Elements, 2009-12-13, (原始內容存檔於2011-07-19) 
  2. ^ April 2012 HTML5 Media Element & WebAudio – WebKit, [2016-02-06], (原始內容存檔於2021-03-08) 
  3. ^ Bug 24364 - Add HTMLMediaElement canPlayType method, WebKit, [2016-02-06], (原始內容存檔於2021-03-08) 
  4. ^ Koivisto, Antti, HTML5 Media Support, WebKit, 2007-11-12 [2016-02-06], (原始內容存檔於2021-09-04) 
  5. ^ Look for "GOOGLE_CHROME_BUILD", [2016-02-06], (原始內容存檔於2021-02-25) 
  6. ^ DiBona, Chris, [whatwg] Google's use of FFmpeg in Chromium and Chrome Was: Re: MPEG-1 subset proposal for HTML5 video codec, Google, 2009-06-01, (原始內容存檔於2011-07-19) 
  7. ^ Origyn Web Browser for MorphOS, Fabian Coeurjoly, [2010-01-04], (原始內容存檔於2010-03-17) 
  8. ^ Holwerda, Thom, Origyn Web Browser 1.7 Supports HTML5 Media, More, OSNews, 2010-03-08 [2010-03-08], (原始內容存檔於2010-03-12) 
  9. ^ HTML Video Codec Support in Chrome, [2010-01-22], (原始內容存檔於2011-06-21) 
  10. ^ Bankoski, Jim, WebM and VP8 land in Chromium, Google, 2010-05-19 [2016-02-06], (原始內容存檔於2010-05-21) 

Presto參考

  1. ^ Pieters, Simon, Everything you need to know about HTML5 video and audio, Opera, 2010-03-10 [2016-02-06], (原始內容存檔於2014-03-29) 
  2. ^ Jägenstedt, Philip, (re-)Introducing <video>, Opera, 2009-12-31, (原始內容存檔於2010-01-04) 
  3. ^ Lie, Håkon Wium, Welcome, WebM <video>!, Opera, 2010-05-19, (原始內容存檔於2011-03-21) 
  4. ^ Mills, Chris, Opera supports the WebM video format, Opera, 2010-05-19 [2016-02-06], (原始內容存檔於2011-04-05) 
  5. ^ Kleinhout, Huib, Opera 10.60 goes final, Opera, 2010-07-01, (原始內容存檔於2010-07-02) 

外部連結