X-Git-Url: https://git.sesse.net/?p=movit;a=blobdiff_plain;f=resample_effect.cpp;fp=resample_effect.cpp;h=a7315689532e85a98a9c2b7884ec52b85f2ed7db;hp=95f5575186ef476b3b8452af0a70838d7a8a37d7;hb=6ec130490868eb8316cb2cdce9fbfd237d25a00e;hpb=15b0642fb679aabc45e6ef778d99494152f233b2 diff --git a/resample_effect.cpp b/resample_effect.cpp index 95f5575..a731568 100644 --- a/resample_effect.cpp +++ b/resample_effect.cpp @@ -717,10 +717,12 @@ void SingleResamplePassEffect::set_gl_state(GLuint glsl_program_num, const strin // We specifically do not want mipmaps on the input texture; // they break minification. Node *self = chain->find_node_for_effect(this); - glActiveTexture(chain->get_input_sampler(self, 0)); - check_error(); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - check_error(); + if (chain->has_input_sampler(self, 0)) { + glActiveTexture(chain->get_input_sampler(self, 0)); + check_error(); + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); + check_error(); + } } } // namespace movit