mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
Mirror of https://git.ffmpeg.org/ffmpeg.git
8f146b526f
In a normal hwaccel, the AVHWFramesContext sets AVFrame.hw_frames_ctx when it initializes a new AVFrame in av_hwframe_get_buffer(). But the VT hwaccel doesn't know what hw_frames_ctx to assign when the AVFrame is first created, because it depends on the format of the pixbuf that the decoder eventually decides to return. Thus newly created AVFrames always have a NULL hw_frames_ctx, and the hwaccel would only assign the ctx once a frame was done decoding. This worked fine with the H264 decoder, but with the HEVC decoder the frame's data may be moved to another empty AVFrame. Since the empty AVFrame never had hw_frames_ctx set, a frame with a NULL ctx could be returned to the API user. This patch works around the issue by moving the derived hw_frames_ctx from the AVFrame to a new VTHWFrame which now holds both the CVPixelBufferRef and the AVBuffer. The hw_frames_ctx is only copied to the AVFrame right before it is about to be returned to the user in videotoolbox_postproc_frame() (since in the case of VT, the hw_frames_ctx is only there for the API user anyway). Fixes playback on macOS and iOS of some hevc videos like https://s3.amazonaws.com/tmm1/videotoolbox/germany-hevc-zdf.ts Signed-off-by: Aman Gupta <aman@tmm1.net> |
||
---|---|---|
compat | ||
doc | ||
ffbuild | ||
fftools | ||
libavcodec | ||
libavdevice | ||
libavfilter | ||
libavformat | ||
libavresample | ||
libavutil | ||
libpostproc | ||
libswresample | ||
libswscale | ||
presets | ||
tests | ||
tools | ||
.gitattributes | ||
.gitignore | ||
.travis.yml | ||
Changelog | ||
configure | ||
CONTRIBUTING.md | ||
COPYING.GPLv2 | ||
COPYING.GPLv3 | ||
COPYING.LGPLv2.1 | ||
COPYING.LGPLv3 | ||
CREDITS | ||
INSTALL.md | ||
LICENSE.md | ||
MAINTAINERS | ||
Makefile | ||
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 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
andqt-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.