mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-27 19:22:49 +01:00
opengl: Unexport BindBuffer
This commit is contained in:
parent
23a832c0a7
commit
5be08cac19
@ -471,7 +471,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer {
|
|||||||
return bf
|
return bf
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Context) BindBuffer(bufferType bufferType, b buffer) {
|
func (c *Context) bindBuffer(bufferType bufferType, b buffer) {
|
||||||
_ = c.runOnContextThread(func() error {
|
_ = c.runOnContextThread(func() error {
|
||||||
gl.BindBuffer(uint32(bufferType), uint32(b))
|
gl.BindBuffer(uint32(bufferType), uint32(b))
|
||||||
return nil
|
return nil
|
||||||
|
@ -420,7 +420,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer {
|
|||||||
return buffer(b)
|
return buffer(b)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Context) BindBuffer(bufferType bufferType, b buffer) {
|
func (c *Context) bindBuffer(bufferType bufferType, b buffer) {
|
||||||
gl := c.gl
|
gl := c.gl
|
||||||
gl.Call("bindBuffer", int(bufferType), js.Value(b))
|
gl.Call("bindBuffer", int(bufferType), js.Value(b))
|
||||||
}
|
}
|
||||||
|
@ -369,7 +369,7 @@ func (c *Context) newElementArrayBuffer(size int) buffer {
|
|||||||
return buffer(b)
|
return buffer(b)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *Context) BindBuffer(bufferType bufferType, b buffer) {
|
func (c *Context) bindBuffer(bufferType bufferType, b buffer) {
|
||||||
gl := c.gl
|
gl := c.gl
|
||||||
gl.BindBuffer(mgl.Enum(bufferType), mgl.Buffer(b))
|
gl.BindBuffer(mgl.Enum(bufferType), mgl.Buffer(b))
|
||||||
}
|
}
|
||||||
|
@ -288,8 +288,8 @@ func (s *openGLState) useProgram(proj []float32, texture Texture, dstW, dstH, sr
|
|||||||
theArrayBufferLayout.enable(program)
|
theArrayBufferLayout.enable(program)
|
||||||
|
|
||||||
if s.lastProgram == zeroProgram {
|
if s.lastProgram == zeroProgram {
|
||||||
c.BindBuffer(arrayBuffer, s.arrayBuffer)
|
c.bindBuffer(arrayBuffer, s.arrayBuffer)
|
||||||
c.BindBuffer(elementArrayBuffer, s.elementArrayBuffer)
|
c.bindBuffer(elementArrayBuffer, s.elementArrayBuffer)
|
||||||
c.uniformInt(program, "texture", 0)
|
c.uniformInt(program, "texture", 0)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user