ACT-CV - Machine Vision for Cognitive Modeling
|
show the current attended location of ACT-Rs vision module More...
#include <FrameObserver.h>
Public Member Functions | |
AttendedLocObs () | |
~AttendedLocObs () | |
void | FrameNotify (IplImage *img, int frameNr) |
void | UpdateAttendedLoc (int x, int y) |
notification about the current location More... | |
void | UpdateMousePos (int x, int y) |
const char * | GetName () const |
the name of the observer More... | |
Public Member Functions inherited from FrameObs | |
virtual void | RegionInfoNotify (const std::vector< RegionInfo > ®ions) |
Public Member Functions inherited from ReferenceCount | |
ReferenceCount () | |
virtual | ~ReferenceCount () |
void | IncRefCount () |
void | DecRefCount () |
Private Member Functions | |
void | PrintCross (IplImage *img) |
mark the current focus by a cross More... | |
Private Member Functions inherited from ImageCopy | |
ImageCopy (int divi=1) | |
~ImageCopy () | |
IplImage * | GetCurCopy () |
IplImage * | GetCopy (IplImage *img, int frameNr) |
Private Attributes | |
GCPointer< FrameObs > | win |
the window More... | |
CvPoint | focus |
the current attended location More... | |
CvPoint | mouse |
the current mouse location More... | |
mhthreads::Mutex | mutex |
mutex for this class More... | |
show the current attended location of ACT-Rs vision module
Instances of this class are manipulated by the video thread and the ACT-R thread. Be careful!
Definition at line 575 of file FrameObserver.h.
AttendedLocObs::AttendedLocObs | ( | ) |
Definition at line 620 of file FrameObserver.h.
AttendedLocObs::~AttendedLocObs | ( | ) |
Definition at line 625 of file FrameObserver.h.
References win.
|
virtual |
called by the video thread
Implements FrameObs.
Definition at line 629 of file FrameObserver.h.
References mhthreads::Mutex::Enter(), FrameObs::FrameNotify(), ImageCopy::GetCopy(), mhthreads::Mutex::Leave(), MHDBGMSG, mutex, PrintCross(), and win.
|
virtual |
the name of the observer
This is used to avoid that two instances of the same observer class are added to the observer list.
Implements FrameObs.
Definition at line 661 of file FrameObserver.h.
Referenced by AttendedLocObs().
|
private |
mark the current focus by a cross
Definition at line 588 of file FrameObserver.h.
References ATTLOC_CROSS_LWIDTH, focus, and mouse.
Referenced by FrameNotify().
void AttendedLocObs::UpdateAttendedLoc | ( | int | x, |
int | y | ||
) |
notification about the current location
called by the ACT-R thread (the "client")
Definition at line 645 of file FrameObserver.h.
References mhthreads::Mutex::Enter(), focus, mhthreads::Mutex::Leave(), MHDBGMSG, and mutex.
void AttendedLocObs::UpdateMousePos | ( | int | x, |
int | y | ||
) |
Definition at line 653 of file FrameObserver.h.
References mhthreads::Mutex::Enter(), mhthreads::Mutex::Leave(), MHDBGMSG, mouse, and mutex.
|
private |
the current attended location
Definition at line 579 of file FrameObserver.h.
Referenced by PrintCross(), and UpdateAttendedLoc().
|
private |
the current mouse location
Definition at line 581 of file FrameObserver.h.
Referenced by PrintCross(), and UpdateMousePos().
|
private |
mutex for this class
Definition at line 583 of file FrameObserver.h.
Referenced by FrameNotify(), UpdateAttendedLoc(), and UpdateMousePos().
the window
Definition at line 577 of file FrameObserver.h.
Referenced by AttendedLocObs(), FrameNotify(), and ~AttendedLocObs().