]> git.sesse.net Git - movit/blobdiff - mix_effect_test.cpp
Merge branch 'master' into epoxy
[movit] / mix_effect_test.cpp
index babb76630dd185cdea4613ff8fc93dc581666d54..b5082846abc13e6ec76ff37d9dfe1ec6b7032ab7 100644 (file)
@@ -1,6 +1,6 @@
 // Unit tests for MixEffect.
 
-#include <GL/glew.h>
+#include <epoxy/gl.h>
 
 #include "effect_chain.h"
 #include "gtest/gtest.h"
@@ -9,6 +9,8 @@
 #include "mix_effect.h"
 #include "test_util.h"
 
+namespace movit {
+
 TEST(MixEffectTest, FiftyFiftyMix) {
        float data_a[] = {
                0.0f, 0.25f,
@@ -100,7 +102,7 @@ TEST(MixEffectTest, AdditiveBlendingWorksForBothTotallyOpaqueAndPartiallyTranslu
                1.0f, 1.0f, 1.0f, 0.7f,
        };
 
-       float out_data[4];
+       float out_data[8];
        EffectChainTester tester(data_a, 1, 2, FORMAT_RGBA_POSTMULTIPLIED_ALPHA, COLORSPACE_sRGB, GAMMA_LINEAR);
        Effect *input1 = tester.get_chain()->last_added_effect();
        Effect *input2 = tester.add_input(data_b, FORMAT_RGBA_POSTMULTIPLIED_ALPHA, COLORSPACE_sRGB, GAMMA_LINEAR);
@@ -138,3 +140,5 @@ TEST(MixEffectTest, MixesLinearlyDespitesRGBInputsAndOutputs) {
 
        expect_equal(expected_data, out_data, 2, 2);
 }
+
+}  // namespace movit