private void bindTextures() { int i = 0; foreach (var pair in _textures) { _graphics.Uniform1(pair.Key, i); _graphics.ActiveTexture(i); _graphics.BindTexture2D(pair.Value); i++; } _graphics.ActiveTexture(0); }