FFmpeg git repo
Go to file
Andreas Rheinhardt 30e1f5ec77 avcodec/startcode: Avoid unaligned accesses
Up until now, ff_startcode_find_candidate_c() simply casts
an uint8_t* to uint64_t*/uint32_t* to read 64/32 bits at a time
in case HAVE_FAST_UNALIGNED is true. Yet this ignores the
alignment requirement of these types as well as effective type
rules of the C standard. This commit therefore replaces these
direct accesses with AV_RN64/32; this also improves
readability.

UBSan reported these unaligned accesses which happened in 233
FATE-tests involving H.264 and VC-1 (this has also been reported
in tickets #8138 and #8485); these tests are fixed by this commit.

The output of GCC with -O3 is unchanged for aarch64, loongarch,
ppc and x64 (as well as for arches like alpha for which
HAVE_FAST_UNALIGNED is never true in the first place).
There was only a slight difference for mips and arm.
I don't know about the speed impact of them.

Reviewed-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-10-19 13:48:31 +02:00
compat
doc ffmpeg: Add display_{rotation, hflip, vflip} options 2022-10-19 11:53:52 +02:00
ffbuild configure: probe RISC-V Vector extension 2022-09-27 13:19:52 +02:00
fftools ffmpeg: Deprecate display rotation override with a metadata key 2022-10-19 11:53:52 +02:00
libavcodec avcodec/startcode: Avoid unaligned accesses 2022-10-19 13:48:31 +02:00
libavdevice avdevice/avdevice: Fix mismatching argument name 2022-10-17 09:51:47 +02:00
libavfilter avfilter: Fix doxy references 2022-10-17 09:56:44 +02:00
libavformat avcodec: ViewQuest VQC decoder 2022-10-18 13:20:37 +11:00
libavutil avutil/samplefmt: document missing argument 2022-10-17 09:56:47 +02:00
libpostproc
libswresample swresample: Fix Doxy reference to AVOptions 2022-10-17 09:55:19 +02:00
libswscale swscale: document some missing arguments 2022-10-17 09:56:47 +02:00
presets
tests ffmpeg: Add display_{rotation, hflip, vflip} options 2022-10-19 11:53:52 +02:00
tools tools/target_dec_fuzzer: Adjust threshold for Jpeg2000 2022-09-16 21:30:59 +02:00
.gitattributes
.gitignore
.mailmap
.travis.yml
Changelog avcodec: ViewQuest VQC decoder 2022-10-18 13:20:37 +11:00
configure avcodec/snow: Move initializing MotionEstContext to snowenc.c 2022-10-12 10:58:15 +02:00
CONTRIBUTING.md
COPYING.GPLv2
COPYING.GPLv3
COPYING.LGPLv2.1
COPYING.LGPLv3
CREDITS
INSTALL.md
LICENSE.md
MAINTAINERS MAINTAINERS: remove the project leader section 2022-09-23 16:06:11 +02:00
Makefile configure: probe RISC-V Vector extension 2022-09-27 13:19:52 +02:00
README.md
RELEASE

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 means to alter decoded audio and video through a directed graph of connected 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.