OLD | NEW |
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 Loading... |
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 | |
155 } // namespace media | 147 } // namespace media |
OLD | NEW |