]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - android/external-libkmsxx.git/blobdiff - py/pykms/pykmsutil.cpp
Add different YCbCr encodings.
[android/external-libkmsxx.git] / py / pykms / pykmsutil.cpp
index cb09dea0ab96285d72c31a1dbb49c1470e208f47..a5a6041a22ebf40c38ce8ee1522973a8ffe7d942 100644 (file)
@@ -40,9 +40,17 @@ void init_pykmstest(py::module &m)
                             py::arg("crtc"),
                             py::arg("format") = PixelFormat::Undefined)
                        ;
+       py::enum_<YUVType>(m, "YUVType")
+                       .value("BT601_Lim", YUVType::BT601_Lim)
+                       .value("BT601_Full", YUVType::BT601_Full)
+                       .value("BT709_Lim", YUVType::BT709_Lim)
+                       .value("BT709_Full", YUVType::BT709_Full)
+                       ;
 
        // Use lambdas to handle IMappedFramebuffer
-       m.def("draw_test_pattern", [](MappedFramebuffer& fb) { draw_test_pattern(fb); } );
+       m.def("draw_test_pattern", [](MappedFramebuffer& fb, YUVType yuvt) { draw_test_pattern(fb, yuvt); },
+             py::arg("fb"),
+             py::arg("yuvt") = YUVType::BT601_Lim);
        m.def("draw_color_bar", [](MappedFramebuffer& fb, int old_xpos, int xpos, int width) {
                draw_color_bar(fb, old_xpos, xpos, width);
        } );