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

Unified Diff: webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m

Issue 2916583005: Ensure the openGLContext is current before trying to reshape the viewport (Closed)
Patch Set: Created 3 years, 7 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m
diff --git a/webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m b/webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m
index 66145fb506cd6b7132e97b7ceb00ab08eace437a..4ca55393e79ab9bd023408600d388f4513e28ebf 100644
--- a/webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m
+++ b/webrtc/sdk/objc/Framework/Classes/UI/RTCNSGLVideoView.m
@@ -77,6 +77,7 @@ - (void)drawRect:(NSRect)rect {
- (void)reshape {
[super reshape];
NSRect frame = [self frame];
+ [self ensureGLContext];
CGLLockContext([[self openGLContext] CGLContextObj]);
glViewport(0, 0, frame.size.width, frame.size.height);
CGLUnlockContext([[self openGLContext] CGLContextObj]);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698