func Anisotropy(max float32) SamplerOption {
	return func(sa *Sampler) {
		C.SamplerAnisotropy(sa.object, C.GLfloat(max))
	}
}
//////////////////////////////////////////////////////////////////////////////
Anisotropy specifies the maximum anisotropy level.
package gl
import (
	"unsafe"
)
import "C"
type Sampler struct {
	object C.GLuint
}
type SamplerOption func(sa *Sampler)
func NewSampler(o ...SamplerOption) Sampler {
	var sa Sampler
	sa.object = C.NewSampler()
	for _, f := range o {
		f(&sa)
	}
	return sa
}
func Minification(fm FilterMode) SamplerOption {
	return func(sa *Sampler) {
		C.SamplerMinification(sa.object, C.GLenum(fm))
	}
}
func Magnification(fm FilterMode) SamplerOption {
	return func(sa *Sampler) {
		C.SamplerMagnification(sa.object, C.GLenum(fm))
	}
}
type FilterMode C.GLuint
const (
	Nearest             FilterMode = C.GL_NEAREST
	Linear              FilterMode = C.GL_LINEAR
	NearestMimapNearest FilterMode = C.GL_NEAREST_MIPMAP_NEAREST
	LinearMipmapNearest FilterMode = C.GL_LINEAR_MIPMAP_NEAREST
	NearestMipmapLinear FilterMode = C.GL_NEAREST_MIPMAP_LINEAR
	LinearMipmapLinear  FilterMode = C.GL_LINEAR_MIPMAP_LINEAR
)
func LevelOfDetail(min, max float32) SamplerOption {
	return func(sa *Sampler) {
		C.SamplerLevelOfDetail(sa.object, C.GLfloat(min), C.GLfloat(max))
	}
}