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

Side by Side Diff: media/base/video_frame.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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_BASE_VIDEO_FRAME_H_ 5 #ifndef MEDIA_BASE_VIDEO_FRAME_H_
6 #define MEDIA_BASE_VIDEO_FRAME_H_ 6 #define MEDIA_BASE_VIDEO_FRAME_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 static scoped_refptr<VideoFrame> CreateHoleFrame(const gfx::Size& size); 243 static scoped_refptr<VideoFrame> CreateHoleFrame(const gfx::Size& size);
244 #endif // defined(VIDEO_HOLE) 244 #endif // defined(VIDEO_HOLE)
245 245
246 static size_t NumPlanes(VideoPixelFormat format); 246 static size_t NumPlanes(VideoPixelFormat format);
247 247
248 // Returns the required allocation size for a (tightly packed) frame of the 248 // Returns the required allocation size for a (tightly packed) frame of the
249 // given coded size and format. 249 // given coded size and format.
250 static size_t AllocationSize(VideoPixelFormat format, 250 static size_t AllocationSize(VideoPixelFormat format,
251 const gfx::Size& coded_size); 251 const gfx::Size& coded_size);
252 252
253 // Returns the actual allocation size for a YUV frame that is created by
DaleCurtis 2015/08/03 21:23:25 Why do we need these two methods again? Can we jus
emircan 2015/08/03 21:41:54 Only VideoFrame::CreateFrame() uses VideoFrame::Al
254 // CreateFrame() method.
255 static size_t AlignedAllocationSize(const scoped_refptr<VideoFrame>& frame);
256
253 // Returns the plane gfx::Size (in bytes) for a plane of the given coded size 257 // Returns the plane gfx::Size (in bytes) for a plane of the given coded size
254 // and format. 258 // and format.
255 static gfx::Size PlaneSize(VideoPixelFormat format, 259 static gfx::Size PlaneSize(VideoPixelFormat format,
256 size_t plane, 260 size_t plane,
257 const gfx::Size& coded_size); 261 const gfx::Size& coded_size);
258 262
259 // Returns horizontal bits per pixel for given |plane| and |format|. 263 // Returns horizontal bits per pixel for given |plane| and |format|.
260 static int PlaneHorizontalBitsPerPixel(VideoPixelFormat format, size_t plane); 264 static int PlaneHorizontalBitsPerPixel(VideoPixelFormat format, size_t plane);
261 265
262 // Returns bits per pixel for given |plane| and |format|. 266 // Returns bits per pixel for given |plane| and |format|.
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 uint32 release_sync_point_; 480 uint32 release_sync_point_;
477 481
478 VideoFrameMetadata metadata_; 482 VideoFrameMetadata metadata_;
479 483
480 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoFrame); 484 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoFrame);
481 }; 485 };
482 486
483 } // namespace media 487 } // namespace media
484 488
485 #endif // MEDIA_BASE_VIDEO_FRAME_H_ 489 #endif // MEDIA_BASE_VIDEO_FRAME_H_
OLDNEW
« no previous file with comments | « content/renderer/media/webrtc/webrtc_video_capturer_adapter.cc ('k') | media/base/video_frame.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698