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

Side by Side Diff: media/mojo/common/mojo_shared_buffer_video_frame.cc

Issue 1769673002: Transfer media::VideoFrame using mojo shared memory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 9 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "media/mojo/common/mojo_shared_buffer_video_frame.h" 5 #include "media/mojo/common/mojo_shared_buffer_video_frame.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 10
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 ALLOW_UNUSED_LOCAL(result); 137 ALLOW_UNUSED_LOCAL(result);
138 DCHECK_EQ(result, MOJO_RESULT_OK); 138 DCHECK_EQ(result, MOJO_RESULT_OK);
139 } 139 }
140 } 140 }
141 141
142 size_t MojoSharedBufferVideoFrame::PlaneOffset(size_t plane) const { 142 size_t MojoSharedBufferVideoFrame::PlaneOffset(size_t plane) const {
143 DCHECK(IsValidPlane(plane, format())); 143 DCHECK(IsValidPlane(plane, format()));
144 return offsets_[plane]; 144 return offsets_[plane];
145 } 145 }
146 146
147 const mojo::SharedBufferHandle& MojoSharedBufferVideoFrame::Handle() const {
148 return shared_buffer_handle_.get();
149 }
150
151 size_t MojoSharedBufferVideoFrame::MappedSize() const {
152 return shared_buffer_size_;
153 }
154
147 } // namespace media 155 } // namespace media
OLDNEW
« no previous file with comments | « media/mojo/common/mojo_shared_buffer_video_frame.h ('k') | media/mojo/interfaces/media_types.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698