31 #ifndef __ORIENTATION__H_
32 #define __ORIENTATION__H_
41 #include <opencv2/opencv.hpp>
45 double length(CvPoint *pnt1, CvPoint *pnt2);
48 int deltaline(CvPoint *pnt1, CvPoint *pnt2,
char ch);
52 int difference(CvPoint *pnt1, CvPoint *pnt2, CvPoint *pnt3, CvPoint *pnt4,
char ch);
55 void fillarray(CvSeq *result);
61 CvPoint centralpoint(CvPoint pnt1, CvPoint pnt2);
64 CvPoint getcentralpoint(IplImage *
image, CvSeq *res);
68 float getorientation(CvPoint pnt1, CvPoint pnt2);
uint32_t data_count
Size of data as stored in buffer (bytes)
Definition: player_interfaces.h:3447
static bool MatchMessage(player_msghdr_t *hdr, int type, int subtype, player_devaddr_t addr)
Helper for message processing.
Definition: message.h:159
Generic message header.
Definition: player.h:161
virtual int MainSetup(void)
Sets up the resources needed by the driver thread.
Definition: driver.h:658
virtual void MainQuit(void)
Cleanup method for driver thread (called when main exits)
Definition: driver.h:664
Encapsulates a device (i.e., a driver bound to an interface)
Definition: device.h:74
const char * ReadString(int section, const char *name, const char *value)
Read a string value.
virtual void Main(void)=0
Main method for driver thread.
int ReadInt(int section, const char *name, int value)
Read an integer value.
#define PLAYER_OPAQUE_DATA_STATE
Data subtype: generic state.
Definition: player_interfaces.h:3429
#define PLAYER_MSGTYPE_DATA
A data message.
Definition: player.h:95
virtual int ProcessMessage(QueuePointer &resp_queue, player_msghdr *hdr, void *data)
Message handler.
#define PLAYER_MSGTYPE_REQ
A request message.
Definition: player.h:106
int ReadDeviceAddr(player_devaddr_t *addr, int section, const char *name, int code, int index, const char *key)
Read a device id.
Class for loading configuration file information.
Definition: configfile.h:196
A device address.
Definition: player.h:145
An autopointer for the message queue.
Definition: message.h:73
#define PLAYER_OPAQUE_REQ_DATA
Req subtype: generic request.
Definition: player_interfaces.h:3435
#define PLAYER_ERROR(msg)
Error message macros.
Definition: error.h:81
Base class for drivers which oeprate with a thread.
Definition: driver.h:552
Reference-counted message objects.
Definition: message.h:132
#define PLAYER_WARN(msg)
Warning message macros.
Definition: error.h:89
#define PLAYER_MSGTYPE_CMD
A command message.
Definition: player.h:99
#define PLAYER_OPAQUE_CMD_DATA
Cmd subtype: generic command.
Definition: player_interfaces.h:3432
data
Definition: player_interfaces.h:3444
Base class for all drivers.
Definition: driver.h:108
#define PLAYER_MSGQUEUE_DEFAULT_MAXLEN
Default maximum length for a message queue.
Definition: player.h:76
uint8_t * data
The data we will be sending.
Definition: player_interfaces.h:3449