OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2015 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #import "RTCVideoFrame.h" | 11 #import "RTCVideoFrame+Private.h" |
12 | 12 |
13 #include "webrtc/base/scoped_ptr.h" | 13 #include "webrtc/base/scoped_ptr.h" |
14 | 14 |
15 #import "webrtc/api/objc/RTCVideoFrame+Private.h" | |
16 | |
17 @implementation RTCVideoFrame { | 15 @implementation RTCVideoFrame { |
18 rtc::scoped_ptr<cricket::VideoFrame> _videoFrame; | 16 rtc::scoped_ptr<cricket::VideoFrame> _videoFrame; |
19 rtc::scoped_refptr<webrtc::VideoFrameBuffer> _i420Buffer; | 17 rtc::scoped_refptr<webrtc::VideoFrameBuffer> _i420Buffer; |
20 } | 18 } |
21 | 19 |
22 - (size_t)width { | 20 - (size_t)width { |
23 return _videoFrame->width(); | 21 return _videoFrame->width(); |
24 } | 22 } |
25 | 23 |
26 - (size_t)height { | 24 - (size_t)height { |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 } | 108 } |
111 return self; | 109 return self; |
112 } | 110 } |
113 | 111 |
114 - (rtc::scoped_refptr<webrtc::VideoFrameBuffer>)i420Buffer { | 112 - (rtc::scoped_refptr<webrtc::VideoFrameBuffer>)i420Buffer { |
115 [self convertBufferIfNeeded]; | 113 [self convertBufferIfNeeded]; |
116 return _i420Buffer; | 114 return _i420Buffer; |
117 } | 115 } |
118 | 116 |
119 @end | 117 @end |
OLD | NEW |