HTML Tutorial | HTML5 Multimedia | Multimedia File Formats
Multimedia File Formats
Before HTML5, each web browser handled support for multimedia file types in its own way.
With HTML5, multimedia files can be used easily without relying on external plug-ins such as Flash.
Web browsers determine a file’s type from its extension.
For example, when a browser sees a file with the .html extension, it treats that file as an HTML file.
Multimedia elements such as video and sound are stored in multimedia files.
These multimedia files can also be stored in a variety of file formats, as shown below.
Video File Formats
Representative video file formats are as follows.
| File format | File extension | Description |
|---|---|---|
| MPEG | .mpg .mpeg | Developed by the Moving Picture Experts Group; uses lossy compression with conversion codecs. |
| MP4 | .mp4 | Developed by the Moving Picture Experts Group; often used for internet streaming because it can provide high-quality video and audio with a small file size. |
| OGV | .ogg | Developed by the Xiph Foundation; an open multimedia file format that is not protected by patents and was developed as an alternative to MP3. |
| WebM | .webm | An open multimedia file format developed with support from Google; uses VP8 as the video codec and Vorbis as the audio codec. |
| AVI | .avi | Developed by Microsoft; a file format for playing video on PCs. |
| WMV | .wmv | Developed by Microsoft; the main streaming file format for Microsoft Windows Media Player. |
| QuickTime | .mov | Developed by Apple; a file format designed to support video on Macintosh computers. |
| RealVideo | .rm .ram | Developed by RealNetworks; a video plug-in file format based on streaming technology. |
| Flash | .swf .flv | Developed by Macromedia; a software file format for creating vector-graphics-based animations. |
The only video file formats officially supported by the HTML5 standard are MP4, WebM, and OGV.
Audio File Formats
Representative audio file formats are as follows.
| File format | File extension | Description |
|---|---|---|
| WAV | .wav | Developed by IBM and Microsoft; the standard audio file format from IBM and Microsoft for playing audio on personal computers. |
| Ogg | .ogg | Developed by the Xiph Foundation; an open multimedia file format that is not protected by patents and was developed as an alternative to MP3. |
| MP3 | .mp3 | Developed by the Moving Picture Experts Group; a lossy compressed file format developed as the MPEG-1 audio standard. |
| MP4 | .mp4 | Developed by the Moving Picture Experts Group; a multimedia container file format defined as part of MPEG-4. MP4 is also a video file format, but it can be used for audio as well. |
| MIDI | .mid .midi | A data transfer standard for exchanging performance information among electronic musical instruments. |
| RealAudio | .rm .ram | Developed by RealNetworks; streaming sound technology for listening to music in real time over the internet. |
| WMA | .wma | Developed by Microsoft; technology that compresses only music data in Microsoft Windows Media technology. |
| AAC | .aac | Developed by Apple; the default audio file format for iPhone, iPod, and iTunes. It uses a standard lossy compression method. |
The only audio file formats officially supported by the HTML5 standard are MP3, WAV, and Ogg.