summaryrefslogtreecommitdiff
path: root/src/libcamera/message.cpp
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-10-28 05:31:12 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-10-29 16:41:54 +0200
commit3d75cc1bd209cf1de909ce5c8c9cec16789708f6 (patch)
tree5e23464cd2bbbefaaa38cbf900c809d81754ffa8 /src/libcamera/message.cpp
parentdf2518b2a3451ad73ebddce056b68edb98ab0f7c (diff)
libcamera: bound_method: Support connection types
Support all connection types in the BoundMethodBase::activePack() method. To support this, add a semaphore to the InvokeMessage to signal delivery. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'src/libcamera/message.cpp')
-rw-r--r--src/libcamera/message.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/libcamera/message.cpp b/src/libcamera/message.cpp
index efafb655..daf65322 100644
--- a/src/libcamera/message.cpp
+++ b/src/libcamera/message.cpp
@@ -119,13 +119,14 @@ Message::Type Message::registerMessageType()
* \brief Construct an InvokeMessage for method invocation on an Object
* \param[in] method The bound method
* \param[in] pack The packed method arguments
+ * \param[in] semaphore The semaphore used to signal message delivery
* \param[in] deleteMethod True to delete the \a method when the message is
* destroyed
*/
InvokeMessage::InvokeMessage(BoundMethodBase *method, void *pack,
- bool deleteMethod)
+ Semaphore *semaphore, bool deleteMethod)
: Message(Message::InvokeMessage), method_(method), pack_(pack),
- deleteMethod_(deleteMethod)
+ semaphore_(semaphore), deleteMethod_(deleteMethod)
{
}
@@ -136,6 +137,12 @@ InvokeMessage::~InvokeMessage()
}
/**
+ * \fn InvokeMessage::semaphore()
+ * \brief Retrieve the message semaphore passed to the constructor
+ * \return The message semaphore
+ */
+
+/**
* \brief Invoke the method bound to InvokeMessage::method_ with arguments
* InvokeMessage::pack_
*/