Fawkes API
Fawkes Development Version
|
Thread aspect to use in FireVision apps. More...
#include <>>
Public Types | |
enum | VisionThreadMode { CYCLIC, CONTINUOUS } |
The operation mode of this vision thread. More... | |
Public Member Functions | |
VisionAspect (VisionThreadMode mode) | |
Constructor. More... | |
virtual | ~VisionAspect () |
Virtual empty Destructor. More... | |
void | init_VisionAspect (firevision::VisionMaster *vision_master) |
Set vision master. More... | |
VisionThreadMode | vision_thread_mode () |
Get the vision thread mode of this thread. More... | |
![]() | |
const std::list< const char * > & | get_aspects () const |
Get list of aspect names attached to a aspected thread. More... | |
Protected Attributes | |
firevision::VisionMaster * | vision_master |
Vision master. More... | |
Additional Inherited Members | |
![]() | |
void | add_aspect (const char *name) |
Add an aspect to a thread. More... | |
Thread aspect to use in FireVision apps.
It is guaranteed that if used properly from within plugins that initVisionAspect() is called before the thread is started and that you can access the vision master via the vision_master member.
A vision thread can be called either cyclic, which means that in every loop the vision master will wait for this vision thread to finish before the next loop. This also means that the thread has to operate in wait-for-wakeup mode. The thread is woken up when a new camera image is available. In general the vision thread should be very fast and under no conditions it should take longer to process an image than to aquire it. The thread can also operate in continuous mode, in this case also the thread has to operate in continuous mode. In this mode the vision application should keep running and the processing is independent from the camera speed. Make sure that you use strict logging on the shared memory camera to ensure healthy pictures.
fawkes::VisionAspect::VisionAspect | ( | VisionThreadMode | mode | ) |
Constructor.
mode | mode to operate in |
Definition at line 55 of file vision.cpp.
References fawkes::Aspect::add_aspect().
|
virtual |
Virtual empty Destructor.
Definition at line 63 of file vision.cpp.
void fawkes::VisionAspect::init_VisionAspect | ( | firevision::VisionMaster * | vision_master | ) |
Set vision master.
vision_master | vision master It is guaranteed that this is called for a logging thread before Thread::start() is called (when running regularly inside Fawkes). |
Definition at line 75 of file vision.cpp.
References vision_master.
Referenced by fawkes::VisionAspectIniFin::init().
VisionAspect::VisionThreadMode fawkes::VisionAspect::vision_thread_mode | ( | ) |
Get the vision thread mode of this thread.
Definition at line 85 of file vision.cpp.
Referenced by fawkes::VisionAspectIniFin::init(), FvBaseThread::register_for_camera(), and FvAqtVisionThreads::set_thread_running().
|
protected |
Vision master.
Definition at line 53 of file vision.h.
Referenced by FvSrSavePipelineThread::finalize(), FvRetrieverThread::finalize(), FvSrSavePipelineThread::init(), FvRetrieverThread::init(), and init_VisionAspect().