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

Side by Side Diff: media/base/video_frame.h

Issue 1286623002: Update padding/alignment constants to match ffmpeg. (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
« no previous file with comments | « no previous file | media/base/video_frame_unittest.cc » ('j') | media/base/video_frame_unittest.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 10 matching lines...) Expand all
21 #if defined(OS_MACOSX) 21 #if defined(OS_MACOSX)
22 #include <CoreVideo/CVPixelBuffer.h> 22 #include <CoreVideo/CVPixelBuffer.h>
23 #include "base/mac/scoped_cftyperef.h" 23 #include "base/mac/scoped_cftyperef.h"
24 #endif 24 #endif
25 25
26 namespace media { 26 namespace media {
27 27
28 class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> { 28 class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> {
29 public: 29 public:
30 enum { 30 enum {
31 kFrameSizeAlignment = 16, 31 // These values are chosen according to like values in FFmpeg. See static
DaleCurtis 2015/08/11 00:31:30 Hmm, I wonder if we should instead add a construct
miu 2015/08/11 02:53:55 +1. This approach wastes memory for the non-ffmpe
32 kFrameSizePadding = 16, 32 // asserts in ffmpeg_common.
33 kFrameSizeAlignment = 32,
34 kFrameSizePadding = 47,
33 kFrameAddressAlignment = 32 35 kFrameAddressAlignment = 32
34 }; 36 };
35 37
36 enum { 38 enum {
37 kMaxPlanes = 4, 39 kMaxPlanes = 4,
38 40
39 kYPlane = 0, 41 kYPlane = 0,
40 kARGBPlane = kYPlane, 42 kARGBPlane = kYPlane,
41 kUPlane = 1, 43 kUPlane = 1,
42 kUVPlane = kUPlane, 44 kUVPlane = kUPlane,
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 uint32 release_sync_point_; 478 uint32 release_sync_point_;
477 479
478 VideoFrameMetadata metadata_; 480 VideoFrameMetadata metadata_;
479 481
480 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoFrame); 482 DISALLOW_IMPLICIT_CONSTRUCTORS(VideoFrame);
481 }; 483 };
482 484
483 } // namespace media 485 } // namespace media
484 486
485 #endif // MEDIA_BASE_VIDEO_FRAME_H_ 487 #endif // MEDIA_BASE_VIDEO_FRAME_H_
OLDNEW
« no previous file with comments | « no previous file | media/base/video_frame_unittest.cc » ('j') | media/base/video_frame_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698