From 5be08cac193c4ea072d17392b9266796f5f33a05 Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Tue, 30 Oct 2018 23:57:40 +0900 Subject: [PATCH] opengl: Unexport BindBuffer --- internal/opengl/context_desktop.go | 2 +- internal/opengl/context_js.go | 2 +- internal/opengl/context_mobile.go | 2 +- internal/opengl/program.go | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/internal/opengl/context_desktop.go b/internal/opengl/context_desktop.go index 15129fa9d..dc8f45169 100644 --- a/internal/opengl/context_desktop.go +++ b/internal/opengl/context_desktop.go @@ -471,7 +471,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer { return bf } -func (c *Context) BindBuffer(bufferType bufferType, b buffer) { +func (c *Context) bindBuffer(bufferType bufferType, b buffer) { _ = c.runOnContextThread(func() error { gl.BindBuffer(uint32(bufferType), uint32(b)) return nil diff --git a/internal/opengl/context_js.go b/internal/opengl/context_js.go index c19aba8e6..b73c21f46 100644 --- a/internal/opengl/context_js.go +++ b/internal/opengl/context_js.go @@ -420,7 +420,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer { return buffer(b) } -func (c *Context) BindBuffer(bufferType bufferType, b buffer) { +func (c *Context) bindBuffer(bufferType bufferType, b buffer) { gl := c.gl gl.Call("bindBuffer", int(bufferType), js.Value(b)) } diff --git a/internal/opengl/context_mobile.go b/internal/opengl/context_mobile.go index 87e18ca24..921f0eee4 100644 --- a/internal/opengl/context_mobile.go +++ b/internal/opengl/context_mobile.go @@ -369,7 +369,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer { return buffer(b) } -func (c *Context) BindBuffer(bufferType bufferType, b buffer) { +func (c *Context) bindBuffer(bufferType bufferType, b buffer) { gl := c.gl gl.BindBuffer(mgl.Enum(bufferType), mgl.Buffer(b)) } diff --git a/internal/opengl/program.go b/internal/opengl/program.go index d8a710fa7..30b19b8d7 100644 --- a/internal/opengl/program.go +++ b/internal/opengl/program.go @@ -288,8 +288,8 @@ func (s *openGLState) useProgram(proj []float32, texture Texture, dstW, dstH, sr theArrayBufferLayout.enable(program) if s.lastProgram == zeroProgram { - c.BindBuffer(arrayBuffer, s.arrayBuffer) - c.BindBuffer(elementArrayBuffer, s.elementArrayBuffer) + c.bindBuffer(arrayBuffer, s.arrayBuffer) + c.bindBuffer(elementArrayBuffer, s.elementArrayBuffer) c.uniformInt(program, "texture", 0) }