05Robot 3.0

- Main Page
- Modules
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Slots | Signals | Public Member Functions | Public Attributes | List of all members
ProcessorObject Class Reference
Computer Vision Module

Wrapper object containing single processor, managing its processing and control pipelines, and properties. More...

`#include <ProcessorObject.h>`

Inheritance diagram for ProcessorObject:

## Public Slots
void | pStart ()
| Starts processor pipeline, sets isRunning to true. More...
void | pProcess (int t1, int t2)
| Waits for input devices semaphore, calls process in Processor. More...
void | pProcessSpecial (QString s)
| Calls processSpecial in Processor. More...
void | pStop ()
| Stops processor pipeline, sets isRunning to true. More...
void | connectInputs (QList< CameraObject * > camList, QList< ProcessorObject * > procList)
| Sets input lists. More...
void | requestImage (void *image, void *camSem)
| Copies first output image to requested place, releases camera semaphore. More...

## Signals
void | frameOut (int id, cv::Mat *frame)
| Emitted at finish of each frame processing. More...
void | writeInfo (QString)
| Data logger. More...

## Public Member Functions
| ProcessorObject (Processor *p, int procType, int procId, QSemaphore *ss)
| Sets processor data, creates processor semaphore. More...
| ~ProcessorObject ()
| Default destructor, deletes corresponding Processor. More...
virtual void | writeXml (QXmlStreamWriter &stream)
| Passes stream to Processor for configuration writing, encapsulates it in Processor class name. More...
virtual void | readXml (QXmlStreamReader &stream)
| Passes stream with matching class name to Processor for configuration reading. More...
Public Member Functions inherited from cXmlIO
| cXmlIO (int _xmlID=0, QObject *parent=nullptr)
virtual QString | sXmlKey ()
| Generates key of XML entry (as name of the serialised class is) More...
virtual void | findInXML (QString &fileName, bool compareXmlID=true)
| serches th file for XML key corr to class name and fill class properties according to entries found More...
virtual void | writeCsvData (QXmlStreamWriter &stream, QString key, const QVector< QVector< double > > &s)
virtual void | writeCsvVector (QXmlStreamWriter &stream, QString key, const QVector< double > &s)
virtual void | readCsvData (QXmlStreamReader &stream, QVector< QVector< double > > &s)
virtual void | readCsvVector (QXmlStreamReader &stream, QVector< double > &s)
virtual void | write64BaseData (QXmlStreamWriter &stream, QString key, const QVector< QVector< double > > &s)
virtual void | read64BaseData (QXmlStreamReader &stream, QVector< QVector< double > > &s)
template<typename T >
void | writeData (QXmlStreamWriter &stream, QString key, const T &data)
template<typename T >
void | readData (QXmlStreamReader &stream, T &data)
int | getXmlID () const
void | setXmlID (int value)

## Public Attributes
QSemaphore * | syncSem
| pointer to synchronisation semaphore shared across all processors More...
QSemaphore * | procSem
| pointer to processor instance-specific semaphore More...
vector< CameraObject * > | connectedDevices
| vector of pointers to cameras connected to this processor More...
vector< ProcessorObject * > | connectedProcessors
| vector of pointers to processor connected to this processor More...
Processor * | proc
| Pointer to Processor. More...
int | processorType
| Processor type, one of ProcessorType enum. More...
int | processorID
| Processor ID, unique integer. More...
bool | isRunning
| Running flag, true while running. More...

## Additional Inherited Members
Static Public Member Functions inherited from cXmlIO
static void | metaCopy (QObject *dest, QObject *src)
Protected Member Functions inherited from cXmlIO
void | metaDataXmlReader (QXmlStreamReader &stream, QObject &obj, bool isUser=true)
void | metaDataXmlWriter (QXmlStreamWriter &stream, const QObject &obj, bool isUser=true)
Properties inherited from cXmlIO
int | xmlID
| Defines uniqe identifier for object in XML file. More...

## Detailed Description

Wrapper object containing single processor, managing its processing and control pipelines, and properties.

## Constructor & Destructor Documentation

ProcessorObject | ( | Processor * | p,
|  | int | procType,
|  | int | procId,
|  | QSemaphore * | ss
| ) |  |
| inline

Sets processor data, creates processor semaphore.

Parameters

  p | pointer to Processor
  procType | Processor type, one of ProcessorType enum
  procId | Processor ID, unique integer
  ss | pointer to synchronisation semaphore shared across all processors

~ProcessorObject | ( |  | ) |
| inline

Default destructor, deletes corresponding Processor.

## Member Function Documentation

void connectInputs | ( | QList< CameraObject * > | camList,
|  | QList< ProcessorObject * > | procList
| ) |  |
| slot

Sets input lists.

Parameters

  camList | list of pointers to input cameras
  procList | list of pointers to input processors

void frameOut | ( | int | id,
|  | cv::Mat * | frame
| ) |  |
| signal

Emitted at finish of each frame processing.

Parameters

  id | frame id (index in output vector)
  frame | pointer to output image

void pProcess | ( | int | t1,
|  | int | t2
| ) |  |
| slot

Waits for input devices semaphore, calls process in Processor.

Parameters

  t1 | Cameras trigger time
  t2 | Cameras acquisition finish time

void pProcessSpecial | ( | QString | s | ) |
| slot

Calls processSpecial in Processor.

Parameters

  s | Command string

void pStart | ( |  | ) |
| slot

Starts processor pipeline, sets isRunning to true.

void pStop | ( |  | ) |
| slot

Stops processor pipeline, sets isRunning to true.

virtual void readXml | ( | QXmlStreamReader & | stream | ) |
| virtual

Passes stream with matching class name to Processor for configuration reading.

Reimplemented from cXmlIO.

void requestImage | ( | void * | image,
|  | void * | camSem
| ) |  |
| slot

Copies first output image to requested place, releases camera semaphore.

Parameters

  image | pointer to cv::Mat to copy output image
  camSem | receiver camera semaphore

void writeInfo | ( | QString |  | ) |
| signal

Data logger.

Parameters

  info | text to log

virtual void writeXml | ( | QXmlStreamWriter & | stream | ) |
| virtual

Passes stream to Processor for configuration writing, encapsulates it in Processor class name.

Reimplemented from cXmlIO.

## Member Data Documentation

vector<CameraObject *> connectedDevices

vector of pointers to cameras connected to this processor

vector<ProcessorObject *> connectedProcessors

vector of pointers to processor connected to this processor

bool isRunning

Running flag, true while running.

Processor* proc

Pointer to Processor.

int processorID

Processor ID, unique integer.

int processorType

Processor type, one of ProcessorType enum.

QSemaphore* procSem

pointer to processor instance-specific semaphore

QSemaphore* syncSem

pointer to synchronisation semaphore shared across all processors

The documentation for this class was generated from the following file:

- processors/ProcessorObject.h