+#include <assert.h>
+
#include "gamma_expansion_effect.h"
#include "util.h"
std::string GammaExpansionEffect::output_glsl()
{
- return read_file("todo.glsl");
+ switch (source_curve) {
+ case GAMMA_LINEAR:
+ return read_file("identity.glsl");
+ case GAMMA_sRGB:
+ return read_file("gamma_expansion_effect_srgb.glsl");
+ case GAMMA_REC_709: // and GAMMA_REC_601
+ return read_file("gamma_expansion_effect_rec709.glsl");
+ default:
+ assert(false);
+ }
}