Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(415)

Unified Diff: media/base/video_frame_pool.h

Issue 1267003004: Revert to zero-initializing buffers for FFmpegVideoDecoder (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/base/video_frame_pool.h
diff --git a/media/base/video_frame_pool.h b/media/base/video_frame_pool.h
index 947e8afd4fd6cfd819c45d743894c54a75cc9d60..32c3b76481c57566973959737838dba9074a45ae 100644
--- a/media/base/video_frame_pool.h
+++ b/media/base/video_frame_pool.h
@@ -25,12 +25,16 @@ class MEDIA_EXPORT VideoFramePool {
// Returns a frame from the pool that matches the specified
// parameters or creates a new frame if no suitable frame exists in
- // the pool.
+ // the pool. The pool is drained if no matching frame is found.
+ // If a new frame must be created and |zero_new_frames| is true, the buffer
+ // for the new frame will be zero initialized. Reused frames will not be zero
+ // initialized.
scoped_refptr<VideoFrame> CreateFrame(VideoPixelFormat format,
const gfx::Size& coded_size,
const gfx::Rect& visible_rect,
const gfx::Size& natural_size,
- base::TimeDelta timestamp);
+ base::TimeDelta timestamp,
+ bool zero_new_frames);
protected:
friend class VideoFramePoolTest;

Powered by Google App Engine
This is Rietveld 408576698