summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2016-06-11 23:42:42 +0300
committerTomi Valkeinen <tomi.valkeinen@ti.com>2016-06-11 23:43:05 +0300
commit22b0d9f08105e235c666865099b85a043761357d (patch)
tree5d21994c574174de4d3ca10c296eb44551493d53
parent126dd1ec3b598a524ebaab40c0b92c14840753ec (diff)
py: PixelFormat & DumbFB impro
-rw-r--r--py/pykmsbase.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/py/pykmsbase.cpp b/py/pykmsbase.cpp
index 3d1998e..d63d4fc 100644
--- a/py/pykmsbase.cpp
+++ b/py/pykmsbase.cpp
@@ -92,10 +92,17 @@ void init_pykmsbase(py::module &m)
py::class_<DumbFramebuffer>(m, "DumbFramebuffer", py::base<Framebuffer>())
.def(py::init<Card&, uint32_t, uint32_t, const string&>(),
py::keep_alive<1, 2>()) // Keep Card alive until this is destructed
+ .def(py::init<Card&, uint32_t, uint32_t, PixelFormat>(),
+ py::keep_alive<1, 2>()) // Keep Card alive until this is destructed
.def_property_readonly("width", &DumbFramebuffer::width)
.def_property_readonly("height", &DumbFramebuffer::height)
;
+ py::enum_<PixelFormat>(m, "PixelFormat")
+ .value("XRGB8888", PixelFormat::XRGB8888)
+ .value("YUYV", PixelFormat::YUYV)
+ ;
+
py::class_<Videomode>(m, "Videomode")
.def(py::init<>())