3 * Copyright (C) 2013 Dan Dennedy <dan@dennedy.org>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software Foundation,
17 * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
23 #include <movit/input.h>
25 class FBOInput : public Input
28 FBOInput(unsigned width, unsigned height);
30 virtual std::string effect_type_id() const { return "FBOInput"; }
32 bool can_output_linear_gamma() const { return false; }
33 AlphaHandling alpha_handling() const { return OUTPUT_POSTMULTIPLIED_ALPHA; }
34 std::string output_fragment_shader();
35 void set_gl_state(GLuint glsl_program_num, const std::string& prefix, unsigned *sampler_num);
36 unsigned get_width() const { return width; }
37 unsigned get_height() const { return height; }
38 Colorspace get_color_space() const { return COLORSPACE_sRGB; }
39 GammaCurve get_gamma_curve() const { return GAMMA_sRGB; }
40 void set_texture(GLuint texture) {
41 texture_num = texture;
47 unsigned width, height;