Go to the documentation of this file.
5 #ifndef CCF_CONTROL_PUB_THREAD_HPP_H_
6 #define CCF_CONTROL_PUB_THREAD_HPP_H_
20 static std::string
GenId(
const std::string& proc_thread_name,
21 const std::string& pub_thread_name);
29 const double period = 0.1);
65 const std::list<ccf::common::PubBase*>&
GetPublishers()
const;
79 bool _CheckMessageBus(
bool& new_data_available,
81 void _GetFrameHandleRef();
82 void _InvokePublishers();
83 void _ReleaseFrameHandle();
85 std::string& diagnostics);
87 std::string m_proc_thr_name;
88 std::string m_pub_thr_id;
89 std::string m_pub_thr_name;
102 std::list<ccf::common::PubBase*> m_publishers;
104 std::map<std::string, ccf::common::PubBase*> m_publisher_map;
107 std::shared_ptr<ccf::common::FrameQueue> m_proc_thr_output_q;
114 #endif // CCF_CONTROL_PUB_THREAD_HPP_H_
Class to be used as parent all CCF classes.
Definition: base.hpp:152
const std::string & GetProcThreadName() const
Return the name of the Publisher.
Definition: pubThread.cpp:306
ccf::PubStatus GetStatus() const
Return Publishing Status of this Publisher Thread.
Definition: pubThread.cpp:247
const std::string & GetPubThreadName() const
Return the name of the Publisher.
Definition: pubThread.cpp:311
IFW CTD Multiprocessing Toolkit Thread base class.
Definition: thread.hpp:29
void SetStatus(const ccf::PubStatus status)
Set the Publishing Status of this Publisher Thread.
Definition: pubThread.cpp:130
static std::string GenId(const std::string &proc_thread_name, const std::string &pub_thread_name)
Generate the Publisher Thread ID used for the interthread communication.
Definition: pubThread.cpp:12
PubThread(const std::string &thread_id, ccf::mptk::MessageBus &message_bus, const double period=0.1)
See ccf::mptk::Thread.
Definition: pubThread.cpp:34
void SetProcThrOutputQ(std::shared_ptr< ccf::common::FrameQueue > &queue)
Set reference to the Output Queue of this Processing Thread.
Definition: pubThread.cpp:117
Status
General status variable.
Definition: base.hpp:202
virtual ~PubThread()
Definition: pubThread.cpp:49
PubStatus
Defines the various possible states of a Data Publisher.
Definition: base.hpp:285
IFW CTD Multiprocessing Toolkit Message Bus.
Definition: messageBus.hpp:30
static void SetStatusAll(const ccf::PubStatus status)
Set the Publishing Status of all Publisher Threads running.
Definition: pubThread.cpp:17
IFW CTD Multiprocessing Toolkit Message class.
Definition: message.hpp:19
const std::list< ccf::common::PubBase * > & GetPublishers() const
Get the list of internal Data Publisher (objects).
Definition: pubThread.cpp:301
The FrameQueue class implements a queue, to manage a set of CCF DataFrame instances as a ring buffer.
Definition: frameQueue.hpp:14
void AddPublisher(ccf::common::PubBase &pub_obj)
Definition: pubThread.cpp:266
Class for implementing CCF Data Publishers.
Definition: pubBase.hpp:114
ccf::common::FrameStatistics & GetFrameStat()
Get reference to frame handling statistics.
Definition: pubThread.cpp:316
void Initialise()
Initialise this thread (object).
Definition: pubThread.cpp:65
Publisher Thread MPTK Thread implementation (see also ccf::mptk::Thread).
Definition: pubThread.hpp:16
uint8_t NbOfPublishers() const
Definition: pubThread.cpp:280
const ccf::common::PubBase & GetPublisher(const uint16_t nb) const
Get the reference to a specific Data Publisher registered in this Publisher Thread (object).
Definition: pubThread.cpp:285
Class used by the threads to store info for generating performance statistics.
Definition: utilities.hpp:25
ccf::common::FrameQueue & GetProcThrOutputQ()
Get reference to the Output Queue of this Processing Thread.
Definition: pubThread.cpp:122
Definition: acqThread.cpp:10
virtual void UserLogic()
Use logic invoked periodically (ccf::mptk::Thread).
Definition: pubThread.cpp:75
Frame class used to store the data and metadata for one frames received from the camera.
Definition: dataFrame.hpp:17