summaryrefslogtreecommitdiff
path: root/src/lib/ffmpeg_decoder.cc
AgeCommit message (Collapse)Author
2022-01-11Fix failure to decode multiple video frames from one packet (#2159).Carl Hetherington
2022-01-11Cleanup: move some stuff into process_video_frame().Carl Hetherington
2022-01-11Use a separate AVFrame for each stream when decoding.Carl Hetherington
This seems to be what ffplay does and it feels like it makes sense as frames may be built from multiple packets AFAICS.
2022-01-07C++11 tidying.Carl Hetherington
2021-10-13Ignore errors from avcodec_send_packet.Carl Hetherington
After seeking it appears that we often get irrelevant errors from this method. ffplay.c seems to ignore them, and this commit means that we do too (just logging them). I think these errors during a non-seeking "encoding" run could be cause for concern; perhaps we should take more note of them in that case.
2021-09-27Replace aligned bool with enum Alignment.Carl Hetherington
2021-09-27Various alignment adjustments.Carl Hetherington
2021-09-13Fix missing subtitles embedded in files decoded by FFmpeg (#2060).Carl Hetherington
Since the FFmpeg 4.4 update it seems that AVSubtitle::pts is no longer set (it's AV_NOPTS_VALUE, i think). Instead we apparently need to get the PTS from the packet, which in turn requires the stream's timebase.
2021-09-13Add missing avsubtitle_free().Carl Hetherington
2021-06-04Fix errors when seeking FFmpeg for some formats.Carl Hetherington
The comments discuss this in a bit more depth, but basically we see errors from avcodec_send_packet after seek. ffplay etc. seem basically to ignore all errors from avcodec_send_packet, and I can't find a "proper" fix, so here's a half-way house hack: ignore some errors after seek. Nasty.
2021-06-03Ignore errors from avcodec_receive_frame when flushing video (#2035).Carl Hetherington
The test fails if we don't do this; it doesn't really seem 100% convincing but we are already doing this for audio.
2021-05-01Switch decoding to ffmpeg send/receive API.Carl Hetherington
2021-05-01Remove some FFmpeg-related warnings by using AVStream::codecpar.Carl Hetherington
2021-04-29C++11 tidying.Carl Hetherington
2021-03-31Add an assert for a function that can fail.Carl Hetherington
2021-03-13Build fix for Ubuntu-16.04-era compilers.Carl Hetherington
2021-03-02Tidy up and do flushing more correctly.v2.15.133Carl Hetherington
This seems necessary with the multi-threaded decoding; it looks like we were doing it quite wrong before but getting away with it.
2021-03-02Rename some subtitle decoding / processing methods.Carl Hetherington
2021-03-02Key _next_time with the audio stream pointer.Carl Hetherington
2021-03-02Remove FFmpeg::_packet.Carl Hetherington
2021-03-02Extract process_audio_frame.Carl Hetherington
2021-03-02Extract audio_stream_from_index.Carl Hetherington
2021-02-28C++11 cleanups.Carl Hetherington
2021-01-13Fix for changes to libsub API.Carl Hetherington
2021-01-07BOOST_FOREACH.Carl Hetherington
2021-01-07std::shared_ptrCarl Hetherington
2020-12-03Obey audio timestamps if they don't deviate by more than some threshold.Carl Hetherington
Previously we would ignore audio timestamps because they are not contiguous in a sample-accurate way. However with bugs like #1833 we do need to obey large discontinuities in audio timestamps, otherwise we get large sync errors. Here we change timestamp handling to ignore small discontinuities in timestamps but not larger ones.
2020-11-23Remove swaroop variant.Carl Hetherington
2020-10-14Don't crash if the first packet in a stream has AV_NOPTS_VALUE;Carl Hetherington
instead, assume it should be at timestamp 0.
2020-10-14Clear out _next_time when seeking, so out-of-date values don'tCarl Hetherington
hang around. Part of the fix for #1857.
2020-07-26Ignore FFmpeg warnings in a nicer way.Carl Hetherington
2020-04-16Added some FIXMEs.Carl Hetherington
2020-02-20Apply FFmpeg palette fix to examination too; fix build with old FFmpeg.Carl Hetherington
2020-02-19Nicer fix for 2D-labelled-3D checking from master.Carl Hetherington
2019-12-19Add an assertion.Carl Hetherington
2019-11-17Fix casting of bytes to words, and hence (hopefully) finally fix incorrect ↵Carl Hetherington
bitmapped subtitle colours.
2019-11-11Make DecoderPart::_position an optional.Carl Hetherington
2019-07-06Add an assertion.Carl Hetherington
2019-06-01Basics of allowing video parts of FFmpegContent to be disabled (#1355 and ↵Carl Hetherington
others).
2019-05-13swaroop: basics of encrypted MP4 playback.Carl Hetherington
2019-05-10Put Time types in dcpomatic namespace.Carl Hetherington
2019-05-05Stop video filters emitting frames from the old position justCarl Hetherington
after a seek. If this happens, we get sequences like 1. emit some video at time 60s 2. seek to 40s 3. video frame emitted from filter at 60.1s; this sets _last_video_time in player so that frames emitted between 40s and 60s are discarded; hence the audio buffers overflow. Should fix #1551.
2018-12-03Work around width/height being 0 in subtitle_codec_context(), seenCarl Hetherington
in the wild in a MP4, apparently from a DVD rip.
2018-11-21Tidy and fix logging.Carl Hetherington
2018-11-21Put Film pointer into Decoder.Carl Hetherington
2018-11-21Take Film pointer out of Content.Carl Hetherington
2018-08-09White space.Carl Hetherington
2018-07-23Tidy up after mass rename.Carl Hetherington
2018-07-23More automated renaming.Carl Hetherington
ActiveCaptions -> ActiveText BitmapCaption -> BitmapText ContentCaption -> ContentText ContentTextCaption -> ContentStringText TextCaptionFileContent -> StringTextFileContent TextCaptionFileDecoder -> StringTextFileDecoder TextCaptionFile -> StringTextFile TextCaption -> StringText PlayerCaption -> PlayerText CaptionContent -> TextContent CaptionDecoder -> TextDecoder CaptionPanel -> TextPanel CaptionView -> TextView CaptionAppearanceDialog -> SubtitleAppearanceDialog CaptionType -> TextType
2018-07-21Basics of multiple captions per content so that DCPContent canCarl Hetherington
hold subs and closed captions.