# Does anyone know how to setup the context for the hires retina display of the MacBook Pro?

**URL:** <https://discourse.glfw.org/t/does-anyone-know-how-to-setup-the-context-for-the-hires-retina-display-of-the-macbook-pro/15>\
**Category:** support\
**Created:** [November 3, 2013, 8:00am UTC](https://discourse.glfw.org/t/does-anyone-know-how-to-setup-the-context-for-the-hires-retina-display-of-the-macbook-pro/15 "2013-11-03T08:00:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex035/uploads/glfw/original/1X/b8cdefe6b61b8d5aee6c43b2c56e9cf5eabecfe4.svg) [@system](https://discourse.glfw.org/u/system)\
**Post date:** [November 3, 2013, 8:00am UTC](https://discourse.glfw.org/t/does-anyone-know-how-to-setup-the-context-for-the-hires-retina-display-of-the-macbook-pro/15/1 "2013-11-03T08:00:43Z")

</div>

**[hudritsch](https://sourceforge.net/u/hudritsch/)** wrote on [Sunday, November 03, 2013](https://sourceforge.net/p/glfw/discussion/247562/thread/1fcf2936/#7c26):

Hi,  
in the old 2.7 version I had no problem with the hires retina display of the macbook pro. In the new 3.0 version my 640 x 400 pixel application starts with the viewport in the lower left corner. As soon as I touch the window bar the viewport spreads to the full window. This happens not clearly reproducable and the viewport drops back some times to the quater window size. I tried both glfwSetWindowSizeCallback and glfwSetFramebufferSizeCallback. What kind of events do I have to listen to?  
Thanks for any help.  
Marcus

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex035/uploads/glfw/original/1X/b8cdefe6b61b8d5aee6c43b2c56e9cf5eabecfe4.svg) [@system](https://discourse.glfw.org/u/system)\
**Post date:** [November 3, 2013, 11:46am UTC](https://discourse.glfw.org/t/does-anyone-know-how-to-setup-the-context-for-the-hires-retina-display-of-the-macbook-pro/15/2 "2013-11-03T11:46:58Z")

</div>

**[elmindreda](https://sourceforge.net/u/elmindreda/)** wrote on [Sunday, November 03, 2013](https://sourceforge.net/p/glfw/discussion/247562/thread/1fcf2936/#65c2):

You should set the viewport to the framebuffer size (which is in pixels) instead of the window size (which is in screen coordinates). OpenGL works with pixels, not screen coordinates.
