summaryrefslogtreecommitdiff
path: root/py/pykms/pykmsbase.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'py/pykms/pykmsbase.cpp')
-rw-r--r--py/pykms/pykmsbase.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/py/pykms/pykmsbase.cpp b/py/pykms/pykmsbase.cpp
index 2f56825..3f0f610 100644
--- a/py/pykms/pykmsbase.cpp
+++ b/py/pykms/pykmsbase.cpp
@@ -103,6 +103,11 @@ void init_pykmsbase(py::module &m)
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("format", &DumbFramebuffer::format)
+ .def_property_readonly("num_planes", &DumbFramebuffer::num_planes)
+ .def("fd", &DumbFramebuffer::prime_fd)
+ .def("stride", &DumbFramebuffer::stride)
+ .def("offset", &DumbFramebuffer::offset)
;
py::enum_<PixelFormat>(m, "PixelFormat")