mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
opengl: Refactoring: Use value type for theContext
This commit is contained in:
parent
f7fa4ed8f9
commit
02b570a8e1
@ -15,16 +15,9 @@
|
||||
package opengl
|
||||
|
||||
import (
|
||||
"math"
|
||||
|
||||
"github.com/hajimehoshi/ebiten/internal/graphics"
|
||||
)
|
||||
|
||||
var (
|
||||
zeroPlus = math.Nextafter32(0, 1)
|
||||
oneMinus = math.Nextafter32(1, 0)
|
||||
)
|
||||
|
||||
var (
|
||||
vertexShader shaderType
|
||||
fragmentShader shaderType
|
||||
@ -74,10 +67,10 @@ type Context struct {
|
||||
context
|
||||
}
|
||||
|
||||
var theContext = &Context{}
|
||||
var theContext Context
|
||||
|
||||
func GetContext() *Context {
|
||||
return theContext
|
||||
return &theContext
|
||||
}
|
||||
|
||||
func (c *Context) bindTexture(t textureNative) {
|
||||
|
Loading…
Reference in New Issue
Block a user