Page 123 - HTML5
P. 123

Firefox       Internet
          Feature                            Chrome                                     Opera       Safari
                                                         (Gecko)       Explorer
          <video>: VP9 and Opus in WebM      29.0        28.0 (28.0)   ?                (Yes)       ?

          <video>: Streaming WebM via
                                             ?           42.0 (42.0)   ?                ?           ?
          MSE

          <video>: Theora and Vorbis in      (Yes)       3.5 (1.9.1)   No support       10.50       No
          Ogg                                                                                       support

          <video>: H.264 and MP3 in MP4      (Yes)       (Yes)         9.0              (Yes)       (Yes)


          <video>: H.264 and AAC in MP4      (Yes)       (Yes)         9.0              (Yes)       3.1

                                             No                                         No
          any other format                               No support    No support                   3.1
                                             support                                    support

        Examples


        Using `` and `` element to display audio/video content

        Use the HTML or <audio> element to embed video/audio content in a document. The video/audio
        element contains one or more video/audio sources. To specify a source, use either the src
        attribute or the <source> element; the browser will choose the most suitable one.

        Audio tag example:

         <!-- Simple video example -->
         <video src="videofile.webm" autoplay poster="posterimage.jpg">
           Sorry, your browser doesn't support embedded videos,
           but don't worry, you can <a href="videofile.webm">download it</a>
           and watch it with your favorite video player!
         </video>

         <!-- Video with subtitles -->
         <video src="foo.webm">
           <track kind="subtitles" src="foo.en.vtt" srclang="en" label="English">
           <track kind="subtitles" src="foo.sv.vtt" srclang="sv" label="Svenska">
         </video>
         <!-- Simple video example -->
         <video width="480" controls poster="https://archive.org/download/WebmVp8Vorbis/webmvp8.gif" >
           <source src="https://archive.org/download/WebmVp8Vorbis/webmvp8.webm" type="video/webm">
           <source src="https://archive.org/download/WebmVp8Vorbis/webmvp8_512kb.mp4" type="video/mp4">
           <source src="https://archive.org/download/WebmVp8Vorbis/webmvp8.ogv" type="video/ogg">
           Your browser doesn't support HTML5 video tag.
         </video>

        Audio tag example:


         <!-- Simple audio playback -->
         <audio src="http://developer.mozilla.org/@api/deki/files/2926/=AudioTest_(1).ogg" autoplay>
           Your browser does not support the <code>audio</code> element.
         </audio>

         <!-- Audio playback with captions -->
         <audio src="foo.ogg">
           <track kind="captions" src="foo.en.vtt" srclang="en" label="English">
           <track kind="captions" src="foo.sv.vtt" srclang="sv" label="Svenska">
         </audio>



        https://riptutorial.com/                                                                             107
   118   119   120   121   122   123   124   125   126   127   128