]> git.sesse.net Git - movit/blobdiff - effect_chain.h
Open up for multiple inputs. We need to re-think the execution algorithm before it...
[movit] / effect_chain.h
index 50d57ec35f108ca27a1e0bd70cb60dc7dccfb3f1..5b6996487c3244a8b7ddb380a840ad8e72c0d730 100644 (file)
@@ -63,10 +63,11 @@ private:
        struct Phase {
                GLint glsl_program_num;
                bool input_needs_mipmaps;
-               std::vector<Effect *> inputs;
+               std::vector<Effect *> inputs;   // Only from other phases; input textures are not counted here.
                std::vector<Effect *> effects;  // In order.
        };
 
+       void set_use_srgb_texture_format(Effect *effect);
        Effect *normalize_to_linear_gamma(Effect *input);
        Effect *normalize_to_srgb(Effect *input);
 
@@ -80,8 +81,9 @@ private:
        void construct_glsl_programs(Effect *start, std::set<Effect *> *completed_effects);
 
        unsigned width, height;
-       ImageFormat input_format, output_format;
+       ImageFormat output_format;
        std::vector<Effect *> effects;
+       std::vector<Input *> inputs;  // Also contained in effects.
        std::map<Effect *, std::string> effect_ids;
        std::map<Effect *, GLuint> effect_output_textures;
        std::map<Effect *, std::vector<Effect *> > outgoing_links;