Index: content/common/gpu/media/video_decode_accelerator_unittest.cc |
diff --git a/content/common/gpu/media/video_decode_accelerator_unittest.cc b/content/common/gpu/media/video_decode_accelerator_unittest.cc |
index 0605fb04aeccc612b14c893bf1daa245f6ff2ba6..8d5ebd36eb921bc91c0567ca30bdd2dc848d09d0 100644 |
--- a/content/common/gpu/media/video_decode_accelerator_unittest.cc |
+++ b/content/common/gpu/media/video_decode_accelerator_unittest.cc |
@@ -143,6 +143,9 @@ const int kMaxFramesToDelayReuse = 64; |
const base::TimeDelta kReuseDelay = base::TimeDelta::FromSeconds(1); |
// Simulate WebRTC and call VDA::Decode 30 times per second. |
const int kWebRtcDecodeCallsPerSecond = 30; |
+// Simulate an adjustment to a larger number of pictures to make sure the |
+// decoder supports an upwards adjustment. |
+const int kExtraPictureBuffers = 2; |
struct TestVideoFile { |
explicit TestVideoFile(base::FilePath::StringType file_name) |
@@ -615,6 +618,8 @@ void GLRenderingVDAClient::ProvidePictureBuffers( |
return; |
std::vector<media::PictureBuffer> buffers; |
+ requested_num_of_buffers += kExtraPictureBuffers; |
+ |
texture_target_ = texture_target; |
for (uint32 i = 0; i < requested_num_of_buffers; ++i) { |
uint32 texture_id; |