]> git.sesse.net Git - movit/blobdiff - deconvolution_sharpen_effect.h
Reduce the amount of arithmetic in the BlurEffect shader a bit.
[movit] / deconvolution_sharpen_effect.h
index 293916fd52da9433d7843ff9ca26c3526a8fdc06..e4cc9a556d224e239e411b98c2c1596374ff182e 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef _DECONVOLUTION_SHARPEN_EFFECT_H
-#define _DECONVOLUTION_SHARPEN_EFFECT_H 1
+#ifndef _MOVIT_DECONVOLUTION_SHARPEN_EFFECT_H
+#define _MOVIT_DECONVOLUTION_SHARPEN_EFFECT_H 1
 
 // DeconvolutionSharpenEffect is an effect that sharpens by way of deconvolution
 // (i.e., trying to reverse the blur kernel, as opposed to just boosting high
 //
 //   Jain, Anil K.: “Fundamentals of Digital Image Processing”, Prentice Hall, 1988.
 
+#include <GL/glew.h>
+#include <Eigen/Dense>
+#include <string>
+
 #include "effect.h"
 
-#include <Eigen/Dense>
+namespace movit {
 
 class DeconvolutionSharpenEffect : public Effect {
 public:
@@ -39,6 +43,7 @@ public:
        }
 
        void set_gl_state(GLuint glsl_program_num, const std::string &prefix, unsigned *sampler_num);
+       virtual AlphaHandling alpha_handling() const { return INPUT_PREMULTIPLIED_ALPHA_KEEP_BLANK; }
 
 private:
        // Input size.
@@ -65,4 +70,6 @@ private:
        void update_deconvolution_kernel();
 };
 
-#endif // !defined(_DECONVOLUTION_SHARPEN_EFFECT_H)
+}  // namespace movit
+
+#endif // !defined(_MOVIT_DECONVOLUTION_SHARPEN_EFFECT_H)