summaryrefslogtreecommitdiff
path: root/src/lib/player.cc
AgeCommit message (Collapse)Author
2021-07-05Use unique_ptr.Carl Hetherington
2021-06-13Ignore incoming data when suspended.Carl Hetherington
Otherwise, for example, some content can be moved and before the pieces have been re-created some video can arrive. Then the video's position will be calculated using the content's new position, causing an apparently big gap in the video which is filled in with black. These extra black frames cause the video buffers to fill up without any audio.
2021-04-01Move 3D-to-2D check (#1941).Carl Hetherington
We were checking for 3D content going into a 2D project in the DCPEncoder, but we also need to do the same thing when exporting. Moving the check into Player::emit_video() means that it is applied to both DCP transcoding and export.
2021-02-15Compile fix for ubuntu-16.04-era gcc.Carl Hetherington
2021-02-15Basic handling of overlapping video (#1848).Carl Hetherington
2021-02-14C++11 cleanups.Carl Hetherington
2021-02-04C++11 tidying.Carl Hetherington
2021-01-31Use enum class for Film::Property.Carl Hetherington
2021-01-31More enum class additions.Carl Hetherington
2021-01-27Use enum class for VideoRange.Carl Hetherington
2021-01-21Adapt for libdcp use of enum class.Carl Hetherington
2021-01-07BOOST_FOREACH.Carl Hetherington
2021-01-07std::shared_ptrCarl Hetherington
2020-12-22Pass fonts from content around as FontData.Carl Hetherington
i.e. as a block of memory rather than a file. Also, get the fonts from the decoder rather than the content. Together, these changes allow us to use fonts from SMPTE DCPs added as content. Before, fonts would be messed up in those cases (#1885).
2020-12-01Changes to crop can be handled with a reset_metadata().Carl Hetherington
While playback is happening we need to do that in the butler's buffers and in the little delay inside Player. This removes the seek on every crop change, making it a lot quicker (#1758).
2020-10-21macOS / new boost build fixes.v2.15.104Carl Hetherington
2020-07-05Add more logging and some missing prefs checkboxes for existing logging.v2.15.87Carl Hetherington
2020-06-19Make Atmos content work more like other content. Now its MXFsv2.15.82Carl Hetherington
are re-written, meaning that they can be encrypted. This (along with the libdcp update) also fixes assorted Atmos bugs.
2020-05-21Fix enabled/disable overlapping video/audio with DCP content (part of #1355)Carl Hetherington
2020-05-20Add a bit more debug logging to the player.Carl Hetherington
2020-05-17Fix empty (black) area calculations when video is set to not be used.Carl Hetherington
2020-05-11Change video content scaling so that it either:Carl Hetherington
1. scales the content up to fit the DCP container, preserving aspect ratio, or 2. stretches the content to a custom aspect ratio, or 3. scales the content to some custom size.
2020-04-23Nicer fix for 86102d30bf0aad89115bbeb3d8aaa2a27a0aa432Carl Hetherington
2020-04-23Add accessor for _playlist.Carl Hetherington
2020-04-23Fix complete failure of preview/playback introduced inv2.15.53Carl Hetherington
4219d4b76c5cd5690b1f4fa0c248d93ced26d05a.
2020-04-15Fix length of player output so it can be either the film's length or ↵Carl Hetherington
playlist's length, as appropriate.
2020-04-14Fix Empty/Player behaviour when using a playlist that is not the same as the ↵Carl Hetherington
Film's. Previously Empty would use the length of the film for its end point. Now it takes a Playlist (rather than a list of Pieces) and uses the length of that playlist for its end point. This fixes #1543, in which single-content audio analysis jobs would run for the whole length of the film, rather than the length of the content, producing strange graphs and incorrect progress reports.
2020-04-14Ignore and report failures to decode frames during playback (#1593).Carl Hetherington
2020-02-16Make a new AudioBuffers constructor and use it to avoid some use of the more ↵Carl Hetherington
complicated copy_from.
2020-02-06Fix crash with bitmapped subs that have zero width or height.Carl Hetherington
2020-01-28Fix deadlock during content examination.Carl Hetherington
Before this fix, the following situation could happen in threads A and B: A: Some DONE signal happens; this triggers setup_pieces which takes a lock on the player mutex. B: FFmpegContent::examine takes a lock on the content mutex. B: FFmpegContent::examine adds a stream B: That causes STREAMS PENDING to be emitted. B: This tries to take a lock on the player mutex so it can update _suspended A: setup_pieces tries to access some content information, hence tries to take a lock on the content mutex. Now B is holding the CL and awaiting the PL and A is holding the PL and awaiting the CL. It feels like the root cause of this is that while setup_pieces is happening another change (which would itself cause setup_pieces) is announced, and this isn't dealt with properly. There are two steps here; _suspended is protected with an atomic rather than using _mutex, and also it can cope with being updated recursively.
2020-01-25Cache film length for Player::pass.Carl Hetherington
2020-01-07Extend the amount of allowed disagreement between the audioCarl Hetherington
coming from the content and the calculated periods of silence. It sees that there is some scope for disagreements here when trim start/end times are rounded to frame boundaries. Fixes #1708.
2019-11-11Fix comment.Carl Hetherington
2019-11-01Increase fudge factor at the boundary between audio signal and silence.Carl Hetherington
2019-09-20Add a warning log when an assertion gets hit.Carl Hetherington
Forward-ported from 4141f01e25abd5050db09ff85da47ff059909669 in master.
2019-09-09Stop crashing when running the hints check on films with silent/black gaps.Carl Hetherington
2019-08-31Primitive subtitle export feature.v2.15.16Carl Hetherington
2019-08-30Make player more tolerant of some DCP errors.Carl Hetherington
2019-07-31Avoid random black gaps between bits of content A and B whenv2.15.15Carl Hetherington
content B has had its start trimmed. In this case when we seek inaccurately in A we previously also seeked inaccurately in B. This meant that at the transition the first frame we see of B may not be the first frame of B. After this we seek accurately in B so that we definitely get to the start of it. This is especially important if the start of B has been trimmed to within two keyframes so that an inaccurate seek is not sufficient.
2019-07-25Optimise decoder_factory for DCPDecoder by offering the old decoderCarl Hetherington
(if available) to recover the list of reels from, rather than having to scan the filesystem again.
2019-07-24Re-work idle handling from previous commit.Carl Hetherington
2019-05-26Potential fix for #1568; we calculate the remaining DCPTime butCarl Hetherington
then convert it back to resampled content frames using the DCP rate rather than the resampled content rate, which seems wrong. If we want to go from metric time to frames we surely have to use the frame rate of the thing we are working with (not the frame rate which that thing will be played back at).
2019-05-24Basic ability to set video range (JPEG/MPEG) at least for YUV content. May ↵Carl Hetherington
not work for RGB. See #1509.
2019-05-10Put Time types in dcpomatic namespace.Carl Hetherington
2019-05-10libdcp API fixes.Carl Hetherington
2019-04-17Fix errors when adding reels containing audio after referenced reels (#1528).v2.13.147Carl Hetherington
2019-03-23Another attempt to fix build.v2.13.135Carl Hetherington
2019-03-23Try to fix Windows build.Carl Hetherington
2019-03-22Fix referencing of trimmed multi-reel DCPs (#1495).Carl Hetherington