H.264

H.264 (MPEG4 AVC) video compression standard features and related information: codecs, containers, playback, etc.
H.264 is a video compression standard adopted by the International Organization for Standardization (ISO). Also known as MPEG-4 part 10 and AVC (advanced video coding).

Advantages of H.264
Compared to MPEG2 (DVD-Video) and MPEG4 ASP (DivX, XviD), H.264 compression works significantly more efficiently, providing better image quality (up to the level unattainable for MPEG2 and MPEG4 ASP) and a size smaller file.
Disadvantages of H.264
The main disadvantage of H.264 is the noticeably higher hardware requirements for encoding and playing video files.
For example, on a computer based on an Intel Pentium 4 processor clocked at 3.2 GHz, it is comfortable (no problem, no jerks) to use the ffdshow test decoder in Windows Vista, only the video is played in “medium” HD resolution – 1280 × 720. The so-called Full-HD video (1920 × 1080), depending on the complexity of the scenes, can already “slow down” noticeably. However, it should be noted that in Windows of the previous generation, XP, Full-HD video on the same computer is played quite smoothly in many cases.
The efficiency of using computer resources during playback depends to some extent on the decoder used.
H.264 decoders
ffdshow tests
A popular free decoder for many video and audio compression formats, including H.264.
CoreAVC
The paid codec is considered the codec that currently consumes the least resources. Since version 1.9.5, it supports decoding using the hardware capabilities of nVidia video cards through the CUDA interface. Modern versions also support the use of the hardware capabilities of ATI (AMD) and Intel graphics cards using the DXVA interface.
H.264 support
H.264 is accepted as a standard for compression of high definition video (HD, HDTV), it is distributed in a new generation of optical media: Blu-ray and HD DVD, it is used on mobile devices, it is compatible with Apple QuickTime, It is spreading in digital television transmission systems, videoconferencing, video surveillance, etc. The de facto standard for multimedia web applications and online video hosting sites like YouTube, Adobe Flash Player has supported direct playback of H.264 videos since version 9.0.115, released in late 2007.
Standards, formats, codecs, containers
The codec and the standard are not the same. A standard is a specification (description) of a compression algorithm (eg H.264), a codec is its specific software implementation (eg x264).
You should also not confuse the format of the data and the format of the container in which this data can be stored. The same data (eg compressed according to the H.264 algorithm by the x264 encoder) can be packed in different containers (eg Matroska, MP4 or AVI). In contrast, a container of the same format (eg MKV) does not have to contain video data in H.264 format; you can easily find a MKV file with a normal DivX video inside.
Data container formats
There are several common container formats, the main ones being MP4, Matroska (MKV), and AVI.
MP4
The official container standard for H.264 video. The main disadvantage of MP4 is that according to the specification, said file can only contain audio in AAC format. This leads to a forced loss of sound quality, for example when backing up DVD movies due to the need to transcode from one lossy compression format (AC3, Dolby Digital) to another (AAC). Purely technically, in an MP4 container you can place the stream of any format, but the ability to play the file on any player will not be guaranteed.
Matroska (Matryoshka, MKV)
AVI
The AVI container generally contains videos in the popular DivX and XviD (MPEG4 ASP) formats. The AVI container is not formally designed to store data encoded in accordance with the H.264 standard and is therefore not generally used for these purposes and in the rare cases of incorrect use of the container, the ability to play the corresponding files.