move gl.Enable call to inside gl context in window creation
This commit is contained in:
parent
80b107c039
commit
7615c055cf
|
@ -131,8 +131,6 @@ func NewWindow(cfg WindowConfig) (*Window, error) {
|
|||
glfw.WindowHint(glfw.OpenGLProfile, glfw.OpenGLCoreProfile)
|
||||
glfw.WindowHint(glfw.OpenGLForwardCompatible, glfw.True)
|
||||
|
||||
gl.Enable(gl.MULTISAMPLE)
|
||||
|
||||
glfw.WindowHint(glfw.Resizable, bool2int[cfg.Resizable])
|
||||
glfw.WindowHint(glfw.Decorated, bool2int[!cfg.Undecorated])
|
||||
glfw.WindowHint(glfw.Floating, bool2int[cfg.AlwaysOnTop])
|
||||
|
@ -170,6 +168,7 @@ func NewWindow(cfg WindowConfig) (*Window, error) {
|
|||
// enter the OpenGL context
|
||||
w.begin()
|
||||
glhf.Init()
|
||||
gl.Enable(gl.MULTISAMPLE)
|
||||
w.end()
|
||||
|
||||
return nil
|
||||
|
|
Loading…
Reference in New Issue