py: Expose AtomicReq::add(std::map<>) method
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Sun, 12 Feb 2017 14:45:46 +0000 (16:45 +0200)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Mon, 13 Feb 2017 07:55:05 +0000 (09:55 +0200)
Only the AtomiqReq::add version that takes a single property is
currently exposed through the Python bindings. Expose the add method
that takes a list of properties as well.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
py/pykms/pykmsbase.cpp

index e45b99699f4a9086b8734869735414566009dcb1..0d5bb86534dfff98e6a18f5e74cfad88a605e758 100644 (file)
@@ -165,6 +165,7 @@ void init_pykmsbase(py::module &m)
                        .def(py::init<Card&>(),
                             py::keep_alive<1, 2>())    // Keep Card alive until this is destructed
                        .def("add", (void (AtomicReq::*)(DrmPropObject*, const string&, uint64_t)) &AtomicReq::add)
+                       .def("add", (void (AtomicReq::*)(DrmPropObject*, const map<string, uint64_t>&)) &AtomicReq::add)
                        .def("test", &AtomicReq::test, py::arg("allow_modeset") = false)
                        .def("commit", &AtomicReq::commit, py::arg("data"), py::arg("allow_modeset") = false)
                        .def("commit_sync", &AtomicReq::commit_sync, py::arg("allow_modeset") = false)