FFmpeg git repo
Go to file
Steinar H. Gunderson 88d80cb975 avcodec/put_bits: Make bit buffers 64-bit
Change BitBuf into uint64_t on 64-bit x86. This means we need to flush the
buffer less often, which is a significant speed win. All other platforms,
including all 32-bit ones, are unchanged. Output bitstream is the same.

All API constraints are kept in place, e.g., you still cannot put_bits()
more than 31 bits at a time. This is so that codecs cannot accidentally
become 64-bit-only or similar.

Benchmarking on transcoding to various formats shows consistently
positive results:

  dnxhd                 25.60 fps ->  26.26 fps ( +2.6%)
  dvvideo               24.88 fps ->  25.17 fps ( +1.2%)
  ffv1                  14.32 fps ->  14.58 fps ( +1.8%)
  huffyuv               58.75 fps ->  63.27 fps ( +7.7%)
  jpegls                 6.22 fps ->   6.34 fps ( +1.8%)
  magicyuv              57.10 fps ->  63.29 fps (+10.8%)
  mjpeg                 48.65 fps ->  49.01 fps ( +0.7%)
  mpeg1video            76.41 fps ->  77.01 fps ( +0.8%)
  mpeg2video            75.99 fps ->  77.43 fps ( +1.9%)
  mpeg4                 80.66 fps ->  81.37 fps ( +0.9%)
  prores                12.35 fps ->  12.88 fps ( +4.3%)
  prores_ks             16.20 fps ->  16.80 fps ( +3.7%)
  rv20                  62.80 fps ->  62.99 fps ( +0.3%)
  utvideo               68.41 fps ->  76.32 fps (+11.6%)

Note that this includes video decoding and all other encoding work,
such as DCTs. If you isolate the actual bit-writing routines, it is
likely to be much more.

Benchmark details: Transcoding the first 30 seconds of Big Buck Bunny
in 1080p, Haswell 2.1 GHz, GCC 8.3, generally quantizer locked to
5.0. (Exceptions: DNxHD needs fixed bitrate, and JPEG-LS is so slow
that I only took the first 10 seconds, not 30.) All runs were done
ten times and single-threaded, top and bottom two results discarded to
get rid of outliers, arithmetic mean between the remaining six.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-07-19 10:59:43 +02:00
compat compat/cuda/ptx2c: remove shell loop; fix BSD sed compat 2020-06-01 22:10:41 -05:00
doc doc/http: Update HTTP protocol options 2020-07-19 08:41:32 +08:00
ffbuild common.mak: Also clean Windows debug files. 2020-03-21 18:46:00 +01:00
fftools ffprobe: Allow unknown format private AVOptions 2020-07-02 19:24:56 +01:00
libavcodec avcodec/put_bits: Make bit buffers 64-bit 2020-07-19 10:59:43 +02:00
libavdevice avdevice/decklink_dec: export timecode with s12m side data 2020-07-15 05:47:14 +08:00
libavfilter avfilter/vf_bilateral: simplify code a little 2020-07-18 10:22:12 +02:00
libavformat avformat/apm: fix variable/structure names and cosmetics 2020-07-19 14:43:04 +10:00
libavresample
libavutil avutil/timecode: add description for SMPTE binary format 2020-07-15 05:47:14 +08:00
libpostproc Bump minor versions after branching 4.3 2020-06-08 22:49:04 +02:00
libswresample Bump minor versions after branching 4.3 2020-06-08 22:49:04 +02:00
libswscale swscale/tests/swscale: use 1 for indicating erros 2020-07-16 17:44:53 +02:00
presets
tests checkasm/vf_blend: use the correct depth parameters to initialize the blend modes 2020-07-12 11:30:23 -03:00
tools dnn_backend_native_layer_mathunary: add atanh support 2020-07-06 12:45:14 +08:00
.gitattributes
.gitignore
.mailmap mailmap: add entry for myself 2020-07-13 11:24:04 +08:00
.travis.yml
CONTRIBUTING.md
COPYING.GPLv2
COPYING.GPLv3
COPYING.LGPLv2.1
COPYING.LGPLv3
CREDITS
Changelog avcodec/hevcdec: Add VDPAU to list of supported formats 2020-07-09 20:54:11 -07:00
INSTALL.md
LICENSE.md
MAINTAINERS MAINTAINERS: add myself and gpg fingerprint 2020-07-17 21:57:18 +02:00
Makefile Makefile: Delete more created files when running "make distclean". 2020-03-11 11:43:01 +01:00
README.md
RELEASE RELEASE: We are after the 4.3 branch point, update for that 2020-06-10 00:20:24 +02:00
configure avdevice/decklink_dec: add support for extracting and outputing klv from vanc 2020-07-03 00:24:59 +02:00

README.md

FFmpeg README

FFmpeg is a collection of libraries and tools to process multimedia content such as audio, video, subtitles and related metadata.

Libraries

  • libavcodec provides implementation of a wider range of codecs.
  • libavformat implements streaming protocols, container formats and basic I/O access.
  • libavutil includes hashers, decompressors and miscellaneous utility functions.
  • libavfilter provides a mean to alter decoded Audio and Video through chain of filters.
  • libavdevice provides an abstraction to access capture and playback devices.
  • libswresample implements audio mixing and resampling routines.
  • libswscale implements color conversion and scaling routines.

Tools

  • ffmpeg is a command line toolbox to manipulate, convert and stream multimedia content.
  • ffplay is a minimalistic multimedia player.
  • ffprobe is a simple analysis tool to inspect multimedia content.
  • Additional small tools such as aviocat, ismindex and qt-faststart.

Documentation

The offline documentation is available in the doc/ directory.

The online documentation is available in the main website and in the wiki.

Examples

Coding examples are available in the doc/examples directory.

License

FFmpeg codebase is mainly LGPL-licensed with optional components licensed under GPL. Please refer to the LICENSE file for detailed information.

Contributing

Patches should be submitted to the ffmpeg-devel mailing list using git format-patch or git send-email. Github pull requests should be avoided because they are not part of our review process and will be ignored.