Optimization for the referenced video case.
authorCarl Hetherington <cth@carlh.net>
Wed, 22 Jun 2016 00:15:45 +0000 (01:15 +0100)
committerCarl Hetherington <cth@carlh.net>
Wed, 22 Jun 2016 00:15:45 +0000 (01:15 +0100)
commitc5fe4e83db7a6fa7263e0d67804fd5a5569bf00a
tree5fb69429e2524c7dbae3e97f462c2f9d8fc10d07
parenta8a0dfd1b21de6c0facf965ab119833ff6f790bf
Optimization for the referenced video case.

With referenced video from a DCP decoder, no video will ever
be fetched from the decoder.  Hence the code to discard given video
will be activated after _decoded builds up to the magic size.

Before this commit the code would attempt to fill with black up to
given frame N (with N very large) from the last frame in _decoded when
_decoded had been trimmed.  This would result in exponential growth
in execution time for the VideoDecoder::give() path.
src/lib/video_decoder.cc