mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 01:15:35 +00:00
app/internal/window,app/internal/gl: move gl.Context to package window
Package gl now only defines opengl types and functions. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+3
-3
@@ -6,8 +6,8 @@ import (
|
||||
"image"
|
||||
"runtime"
|
||||
|
||||
"gioui.org/app/internal/gl"
|
||||
"gioui.org/app/internal/gpu"
|
||||
"gioui.org/app/internal/window"
|
||||
"gioui.org/op"
|
||||
)
|
||||
|
||||
@@ -36,7 +36,7 @@ type frameResult struct {
|
||||
err error
|
||||
}
|
||||
|
||||
func newLoop(ctx gl.Context) (*renderLoop, error) {
|
||||
func newLoop(ctx window.Context) (*renderLoop, error) {
|
||||
l := &renderLoop{
|
||||
frames: make(chan frame),
|
||||
results: make(chan frameResult),
|
||||
@@ -54,7 +54,7 @@ func newLoop(ctx gl.Context) (*renderLoop, error) {
|
||||
return l, nil
|
||||
}
|
||||
|
||||
func (l *renderLoop) renderLoop(glctx gl.Context) error {
|
||||
func (l *renderLoop) renderLoop(glctx window.Context) error {
|
||||
// GL Operations must happen on a single OS thread, so
|
||||
// pass initialization result through a channel.
|
||||
initErr := make(chan error)
|
||||
|
||||
Reference in New Issue
Block a user