Advertisement
Guest User

Untitled

a guest
Apr 24th, 2014
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. glfwSetKeyCallback(window, [this](GLFWwindow * window, int key, int scancode, int action, int mods){
  2. addCommand(m_events.at(key));
  3. });
  4.  
  5. glfwSetWindowUserPointer(window, this);
  6. glfwSetKeyCallback(window, [](GLFWwindow * window, int key, int scancode, int action, int mods){
  7.  
  8. Window * win = static_cast<Window *>(glfwGetWindowUserPointer(window));
  9. win->addCommand(win->m_events.at(key));
  10.  
  11. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement