示例#1
0
func (c *Context) IsTexture(t Texture) bool {
	r := false
	_ = c.runOnContextThread(func() error {
		r = gl.IsTexture(uint32(t))
		return nil
	})
	return r
}
示例#2
0
func (c *Context) DeleteTexture(t Texture) {
	_ = c.runOnContextThread(func() error {
		tt := uint32(t)
		if !gl.IsTexture(tt) {
			return nil
		}
		if c.lastTexture == t {
			c.lastTexture = invalidTexture
		}
		gl.DeleteTextures(1, &tt)
		return nil
	})
}
示例#3
0
文件: gl_opengl.go 项目: tanema/amore
// IsTexture reports if t is a valid texture.
//
// http://www.khronos.org/opengles/sdk/docs/man3/html/glIsTexture.xhtml
func IsTexture(t Texture) bool {
	return gl.IsTexture(t.Value)
}