# Using glfw in the existing opengl window

**URL:** <https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093>\
**Category:** support\
**Created:** [February 25, 2018, 6:22pm UTC](https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093 "2018-02-25T18:22:29Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dwnste](https://avatars.discourse-cdn.com/v4/letter/d/e9a140/32.png) [@dwnste](https://discourse.glfw.org/u/dwnste)\
**Post date:** [February 25, 2018, 6:22pm UTC](https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093/1 "2018-02-25T18:22:29Z")

</div>

Hello! Is there any workaround which could help me to use glfw in the existing opengl window without new window creation?

---

<div class="post-metadata">

**Author:** ![elmindreda](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.glfw.org/elmindreda/32/26_2.png) [@elmindreda](https://discourse.glfw.org/u/elmindreda)\
**Post date:** [February 25, 2018, 7:17pm UTC](https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093/2 "2018-02-25T19:17:43Z")

</div>

If you’re on Windows you can try the [attach-win32-window](https://github.com/glfw/glfw/tree/attach-win32-window) branch.

---

<div class="post-metadata">

**Author:** ![dwnste](https://avatars.discourse-cdn.com/v4/letter/d/e9a140/32.png) [@dwnste](https://discourse.glfw.org/u/dwnste)\
**Post date:** [February 25, 2018, 8:45pm UTC](https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093/3 "2018-02-25T20:45:42Z")

</div>

Thanks for the reply! Yep, I saw that branch, but unfortunately I’m on OS X.

---

<div class="post-metadata">

**Author:** ![elmindreda](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.glfw.org/elmindreda/32/26_2.png) [@elmindreda](https://discourse.glfw.org/u/elmindreda)\
**Post date:** [February 25, 2018, 9:22pm UTC](https://discourse.glfw.org/t/using-glfw-in-the-existing-opengl-window/1093/4 "2018-02-25T21:22:57Z")

</div>

macOS is the platform that will require the most work for this. In the meantime, the OpenGL support in Cocoa is relatively simple to use.
