← Back

Decode H.261 video using the <video> tag

H.261 is the first of the ITU-T video recommendations, published in 1988 for videoconferencing over ISDN, and every later one - H.262, H.263, H.264 - is a descendant of the block-based hybrid design it introduced. It is also the only one of the four with no free standalone decoder: ffmpeg-h26x_1 is a build of FFmpeg reduced to the H.261 and H.263 decoders alone, which is why it weighs under a megabyte rather than the several that a full libavcodec would.

The stream sits in an AVI, because H.261 predates every container GPAC muxes. avidmx_1 now recognises the H261 compressor fourcc and tags the pid with it; nothing else in the chain is specific to this format. All 50 frames come out at 59.4 dB PSNR against a native FFmpeg decode.

Code snippet

<video is="universal-video_1" src="testcard.avi" using="solver_1"
        with="avidmx_1;ffmpeg-h26x_1;isobmff_1;libx264_1" controls> </video>

H.261 allows only two picture sizes, QCIF (176x144) and CIF (352x288), and has no notion of a key frame: the decoder logs first frame is no keyframe on any H.261 stream, which is a statement about the format rather than about this file.

Specifications :

The specifications of the test sequence are :

Format H.261 in AVI, 352x288 (CIF), 25 fps, 50 frames
FileSize 124 Ko
Solver solver_1