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

Unified Diff: talk/app/webrtc/objc/RTCI420Frame.mm

Issue 1838353004: cricket::VideoFrame cleanup. New width() and height(). Deleted GetChroma* methods. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fix int vs size_t comparison. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | talk/app/webrtc/objc/RTCVideoRendererAdapter.mm » ('j') | webrtc/api/objc/RTCVideoFrame.mm » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: talk/app/webrtc/objc/RTCI420Frame.mm
diff --git a/talk/app/webrtc/objc/RTCI420Frame.mm b/talk/app/webrtc/objc/RTCI420Frame.mm
index d8be8ceed14e1aa85b2ca9e95e44ba00b0bea66f..b0f1a33b716cc78a32c91e3ed9beb2349e8ec1b3 100644
--- a/talk/app/webrtc/objc/RTCI420Frame.mm
+++ b/talk/app/webrtc/objc/RTCI420Frame.mm
@@ -36,23 +36,23 @@
}
- (NSUInteger)width {
- return _videoFrame->GetWidth();
+ return _videoFrame->width();
}
- (NSUInteger)height {
- return _videoFrame->GetHeight();
+ return _videoFrame->height();
}
- (NSUInteger)chromaWidth {
- return _videoFrame->GetChromaWidth();
+ return ([self width] + 1) / 2;
tkchin_webrtc 2016/03/30 17:35:06 Is this always going to be true? This assumes that
tkchin_webrtc 2016/03/30 17:35:06 dot syntax for properties self.width self.height s
perkj_webrtc 2016/03/31 04:58:23 Are these actually used for anything? Cant we just
nisse-webrtc 2016/03/31 08:22:17 Done.
nisse-webrtc 2016/03/31 08:22:18 This is no change in behavior. Probably with the m
}
- (NSUInteger)chromaHeight {
- return _videoFrame->GetChromaHeight();
+ return ([self height] + 1) / 2;
}
- (NSUInteger)chromaSize {
perkj_webrtc 2016/03/31 04:58:23 dito? Unused?
nisse-webrtc 2016/03/31 08:22:17 The chromaSize property appear to be completely un
pbos-webrtc 2016/03/31 14:49:09 Can you put a TODO here to do that?
- return _videoFrame->GetChromaSize();
+ return [self chromaWidth] * [self chromaHeight];
}
- (const uint8_t*)yPlane {
« no previous file with comments | « no previous file | talk/app/webrtc/objc/RTCVideoRendererAdapter.mm » ('j') | webrtc/api/objc/RTCVideoFrame.mm » ('J')

Powered by Google App Engine
This is Rietveld 408576698