mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 17:35:36 +00:00
gpu/gl: remove OpenGL functions parameter from NewBackend
As a consequence, most API is gone from gpu/gl, and embedding Gio in foreign frameworks don't need to provide an OpenGL implementation. The next change simplifies the GLFW embedding example accordingly. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
@@ -5,9 +5,9 @@
|
||||
package window
|
||||
|
||||
import (
|
||||
"gioui.org/app/internal/glimpl"
|
||||
"gioui.org/gpu/backend"
|
||||
"gioui.org/gpu/gl"
|
||||
"gioui.org/internal/glimpl"
|
||||
)
|
||||
|
||||
/*
|
||||
@@ -43,14 +43,13 @@ func newContext(w *window) (*context, error) {
|
||||
ctx := C.gio_contextForView(view)
|
||||
c := &context{
|
||||
ctx: ctx,
|
||||
c: new(glimpl.Functions),
|
||||
view: view,
|
||||
}
|
||||
return c, nil
|
||||
}
|
||||
|
||||
func (c *context) Backend() (backend.Device, error) {
|
||||
return gl.NewBackend(c.c)
|
||||
return gl.NewBackend(nil)
|
||||
}
|
||||
|
||||
func (c *context) Release() {
|
||||
|
||||
Reference in New Issue
Block a user