mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-03 08:25:34 +00:00
ui/app/internal/gpu: introduce caps and context
Enables graceful fallback to OpenGL ES 2 and WebGL. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
@@ -9,13 +9,13 @@ import (
|
||||
)
|
||||
|
||||
type timers struct {
|
||||
ctx *gl.Functions
|
||||
ctx *context
|
||||
timers []*timer
|
||||
}
|
||||
|
||||
type timer struct {
|
||||
Elapsed time.Duration
|
||||
ctx *gl.Functions
|
||||
ctx *context
|
||||
obj gl.Query
|
||||
state timerState
|
||||
}
|
||||
@@ -28,7 +28,7 @@ const (
|
||||
timerWaiting
|
||||
)
|
||||
|
||||
func newTimers(ctx *gl.Functions, exts string) *timers {
|
||||
func newTimers(ctx *context) *timers {
|
||||
return &timers{
|
||||
ctx: ctx,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user