Make ScreenCapturerMac work in versions of OSX before Lion.
The screen capturer was broken when moving code to webrtc: width and height parameters for glReadPixels were swapped by mistkake. BUG=crbug.com/244102 R=alexeypa@chromium.org Review URL: https://webrtc-codereview.appspot.com/1678005 git-svn-id: http://webrtc.googlecode.com/svn/trunk@4239 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
9e182795a9
commit
a20eb91154
@ -482,7 +482,7 @@ void ScreenCapturerMac::GlBlitFast(const DesktopFrame& frame,
|
||||
|
||||
CGLContextObj CGL_MACRO_CONTEXT = cgl_context_;
|
||||
glBindBufferARB(GL_PIXEL_PACK_BUFFER_ARB, pixel_buffer_object_.get());
|
||||
glReadPixels(0, 0, frame.size().height(), frame.size().width(), GL_BGRA,
|
||||
glReadPixels(0, 0, frame.size().width(), frame.size().height(), GL_BGRA,
|
||||
GL_UNSIGNED_BYTE, 0);
|
||||
GLubyte* ptr = static_cast<GLubyte*>(
|
||||
glMapBufferARB(GL_PIXEL_PACK_BUFFER_ARB, GL_READ_ONLY_ARB));
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user