]> git.sesse.net Git - movit/blobdiff - ycbcr_input_test.cpp
Add a missing entry in .gitignore.
[movit] / ycbcr_input_test.cpp
index f9be19392cf421ff0e2f127a45188045ded1df86..ee77e4c35e07314aee7fc21153efc4635613e78f 100644 (file)
@@ -1,15 +1,17 @@
 // Unit tests for YCbCrInput.
-// FIXME: This class really ought to support mipmaps.
 
+#include <epoxy/gl.h>
 #include <stddef.h>
 
 #include "effect_chain.h"
 #include "gtest/gtest.h"
 #include "test_util.h"
-#include "ycbcr_input.h"
 #include "util.h"
+#include "ycbcr_input.h"
 
-TEST(YCbCrInput, Simple444) {
+namespace movit {
+
+TEST(YCbCrInputTest, Simple444) {
        const int width = 1;
        const int height = 5;
 
@@ -62,7 +64,7 @@ TEST(YCbCrInput, Simple444) {
        expect_equal(expected_data, out_data, 4 * width, height, 0.025, 0.002);
 }
 
-TEST(YCbCrInput, FullRangeRec601) {
+TEST(YCbCrInputTest, FullRangeRec601) {
        const int width = 1;
        const int height = 5;
 
@@ -116,7 +118,7 @@ TEST(YCbCrInput, FullRangeRec601) {
        expect_equal(expected_data, out_data, 4 * width, height, 0.025, 0.002);
 }
 
-TEST(YCbCrInput, Rec709) {
+TEST(YCbCrInputTest, Rec709) {
        const int width = 1;
        const int height = 5;
 
@@ -169,7 +171,7 @@ TEST(YCbCrInput, Rec709) {
        expect_equal(expected_data, out_data, 4 * width, height, 0.025, 0.002);
 }
 
-TEST(YCbCrInput, Rec2020) {
+TEST(YCbCrInputTest, Rec2020) {
        const int width = 1;
        const int height = 5;
 
@@ -224,7 +226,7 @@ TEST(YCbCrInput, Rec2020) {
        expect_equal(expected_data, out_data, 4 * width, height, 0.025, 0.002);
 }
 
-TEST(YCbCrInput, Subsampling420) {
+TEST(YCbCrInputTest, Subsampling420) {
        const int width = 4;
        const int height = 4;
 
@@ -285,7 +287,7 @@ TEST(YCbCrInput, Subsampling420) {
        expect_equal(expected_data, out_data, width, height, 0.01, 0.001);
 }
 
-TEST(YCbCrInput, Subsampling420WithNonCenteredSamples) {
+TEST(YCbCrInputTest, Subsampling420WithNonCenteredSamples) {
        const int width = 4;
        const int height = 4;
 
@@ -347,7 +349,7 @@ TEST(YCbCrInput, Subsampling420WithNonCenteredSamples) {
 }
 
 // Yes, some 4:2:2 formats actually have this craziness.
-TEST(YCbCrInput, DifferentCbAndCrPositioning) {
+TEST(YCbCrInputTest, DifferentCbAndCrPositioning) {
        const int width = 4;
        const int height = 4;
 
@@ -417,7 +419,7 @@ TEST(YCbCrInput, DifferentCbAndCrPositioning) {
        expect_equal(expected_data_blue, out_data, width, height, 0.01, 0.001);
 }
 
-TEST(YCbCrInput, PBO) {
+TEST(YCbCrInputTest, PBO) {
        const int width = 1;
        const int height = 5;
 
@@ -473,3 +475,5 @@ TEST(YCbCrInput, PBO) {
 
        glDeleteBuffers(1, &pbo);
 }
+
+}  // namespace movit