mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 18:58:54 +01:00
opengl: Should access the prototype of WebGLRenderingContext on Safari (#293)
This commit is contained in:
parent
3e2f2e9f08
commit
74c552ea6c
@ -62,7 +62,8 @@ func (p Program) id() programID {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
c := js.Global.Get("WebGLRenderingContext")
|
// Accessing the prototype is rquired on Safari.
|
||||||
|
c := js.Global.Get("WebGLRenderingContext").Get("prototype")
|
||||||
Nearest = Filter(c.Get("NEAREST").Int())
|
Nearest = Filter(c.Get("NEAREST").Int())
|
||||||
Linear = Filter(c.Get("LINEAR").Int())
|
Linear = Filter(c.Get("LINEAR").Int())
|
||||||
VertexShader = ShaderType(c.Get("VERTEX_SHADER").Int())
|
VertexShader = ShaderType(c.Get("VERTEX_SHADER").Int())
|
||||||
|
Loading…
Reference in New Issue
Block a user