// Terminate closes the window, if open, and kills any running threads. This // function should be called before a program exits func Terminate() { C.glfwTerminate() }
// Terminate destroys all remaining windows, frees any allocated resources and // sets the library to an uninitialized state. Once this is called, you must // again call Init successfully before you will be able to use most GLFW // functions. // // If GLFW has been successfully initialized, this function should be called // before the program exits. If initialization fails, there is no need to call // this function, as it is called by Init before it returns failure. // // This function may only be called from the main thread. func Terminate() { flushErrors() C.glfwTerminate() }