-void Effect::register_1d_texture(const std::string &key, float *values, size_t size)
-{
- assert(params_tex_1d.count(key) == 0);
-
- Texture1D tex;
- tex.values = values;
- tex.size = size;
- tex.needs_update = false;
- glGenTextures(1, &tex.texture_num);
-
- glBindTexture(GL_TEXTURE_1D, tex.texture_num);
- check_error();
- glTexParameteri(GL_TEXTURE_1D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
- check_error();
- glTexParameteri(GL_TEXTURE_1D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
- check_error();
- glTexImage1D(GL_TEXTURE_1D, 0, GL_LUMINANCE16F_ARB, size, 0, GL_LUMINANCE, GL_FLOAT, values);
- check_error();
-
- params_tex_1d[key] = tex;
-}
-
-void Effect::invalidate_1d_texture(const std::string &key)