Chromium Code Reviews| Index: webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoFrame.h |
| diff --git a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoFrame.h b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoFrame.h |
| index bfad6088970ac7cc30dcf0c2e1d44885b895a992..6f062f814e8de9a3f0860b10b4e6c9c62f3fe413 100644 |
| --- a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoFrame.h |
| +++ b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoFrame.h |
| @@ -20,20 +20,20 @@ RTC_EXPORT |
| @interface RTCVideoFrame : NSObject |
| /** Width without rotation applied. */ |
| -@property(nonatomic, readonly) size_t width; |
| +@property(nonatomic, readonly) int width; |
| /** Height without rotation applied. */ |
| -@property(nonatomic, readonly) size_t height; |
| +@property(nonatomic, readonly) int height; |
| @property(nonatomic, readonly) int rotation; |
| -@property(nonatomic, readonly) size_t chromaWidth; |
| -@property(nonatomic, readonly) size_t chromaHeight; |
| -// These can return NULL if the object is not backed by a buffer. |
| -@property(nonatomic, readonly, nullable) const uint8_t *yPlane; |
| -@property(nonatomic, readonly, nullable) const uint8_t *uPlane; |
| -@property(nonatomic, readonly, nullable) const uint8_t *vPlane; |
| -@property(nonatomic, readonly) int32_t yPitch; |
| -@property(nonatomic, readonly) int32_t uPitch; |
| -@property(nonatomic, readonly) int32_t vPitch; |
| +/** Accessing YUV data should only be done for I420 frames, i.e. if nativeHandle |
| + * is null. It is always possible to get such a frame by calling convertToI420. |
| + */ |
| +@property(nonatomic, readonly, nullable) const uint8_t *dataY; |
| +@property(nonatomic, readonly, nullable) const uint8_t *dataU; |
| +@property(nonatomic, readonly, nullable) const uint8_t *dataV; |
| +@property(nonatomic, readonly) int strideY; |
| +@property(nonatomic, readonly) int strideU; |
| +@property(nonatomic, readonly) int strideV; |
| /** Timestamp in nanoseconds. */ |
| @property(nonatomic, readonly) int64_t timeStampNs; |
| @@ -43,10 +43,10 @@ RTC_EXPORT |
| - (instancetype)init NS_UNAVAILABLE; |
| -/** If the frame is backed by a CVPixelBuffer, creates a backing i420 frame. |
| - * Calling the yuv plane properties will call this method if needed. |
| +/** Return a frame that is guaranteed to be I420, i.e. it is possible to access |
| + * the YUV data on it. |
| */ |
| -- (void)convertBufferIfNeeded; |
| +- (RTCVideoFrame*)convertToI420; |
|
daniela-webrtc
2017/02/17 16:26:34
Nit: pointer spacing, here and in other places as
magjed_webrtc
2017/02/20 16:16:44
Done.
|
| @end |