#include <VideoManager.h>
Public Types | |
typedef void(* | SignalF )(void *, const JpegReader *, unsigned int) |
Public Member Functions | |
bool | close () |
bool | getImageSize (unsigned int *width, unsigned int *height) |
double | getObservedFrameRate () |
double | getRequiredFrameRate () |
bool | isPaused () const |
bool | isRecording () const |
bool | open (const char *hostname, unsigned int port) |
bool | pause () |
bool | resume () |
void | setDestination (unsigned char *dst) |
void | setFrameRate (double fps) |
bool | setImageSize (unsigned int width, unsigned int height) |
void | setMaxFrameRate () |
void | setRecordingBasename (const char *bname) |
void | setRecordingDestination (const char *dirname) |
void | setSignalFunction (SignalF f, void *arg) |
void | setVerboseLevel (unsigned int v) |
void | setVideoOutputColorSpace (JpegReader::ColorSpace cspace) |
void | startRecording () |
void | stopRecording () |
VideoManager () | |
~VideoManager () | |
Protected Member Functions | |
bool | checkSocketState () |
bool | decodeImage () |
bool | receiveOneFrame () |
bool | reconnect () |
bool | requestNextImage () |
bool | requestNextImageIfNecessary () |
bool | sendInitSeq () |
Protected Attributes | |
unsigned char * | destination |
unsigned int | frame |
unsigned int | height |
pthread_mutex_t | initMtx |
double | interImageDelay |
JpegReader * | jpeg |
double | lastFrameTimeStamp |
double | observedFrameRate |
bool | paused |
bool | readyToRequest |
pthread_t | rec_thr_id |
VideoGram | reception |
pthread_t | req_thr_id |
pthread_cond_t | reqCond |
pthread_mutex_t | reqMtx |
bool | savestream |
SignalF | signal |
void * | signalarg |
pthread_mutex_t | sockMtx |
JpegStreamSaver | ssaver |
bool | terminate |
unsigned int | verbose |
Socket * | videosock |
unsigned int | width |
Friends | |
void * | video_reception_thread (void *thrarg) |
void * | video_request_thread (void *thrarg) |
Definition at line 9 of file VideoManager.h.
typedef void(* VideoManager::SignalF)(void *, const JpegReader *, unsigned int) |
Definition at line 12 of file VideoManager.h.
Definition at line 10 of file VideoManager.cpp.
Definition at line 42 of file VideoManager.cpp.
bool VideoManager::checkSocketState | ( | ) | [protected] |
Definition at line 189 of file VideoManager.cpp.
bool VideoManager::close | ( | ) |
Definition at line 282 of file VideoManager.cpp.
bool VideoManager::decodeImage | ( | ) | [protected] |
Definition at line 105 of file VideoManager.cpp.
bool VideoManager::getImageSize | ( | unsigned int * | width, |
unsigned int * | height | ||
) |
Definition at line 317 of file VideoManager.cpp.
double VideoManager::getObservedFrameRate | ( | ) |
Definition at line 515 of file VideoManager.cpp.
double VideoManager::getRequiredFrameRate | ( | ) |
Definition at line 508 of file VideoManager.cpp.
bool VideoManager::isPaused | ( | ) | const [inline] |
Definition at line 60 of file VideoManager.h.
bool VideoManager::isRecording | ( | ) | const [inline] |
Definition at line 64 of file VideoManager.h.
bool VideoManager::open | ( | const char * | hostname, |
unsigned int | port | ||
) |
Definition at line 221 of file VideoManager.cpp.
bool VideoManager::pause | ( | ) |
Definition at line 476 of file VideoManager.cpp.
bool VideoManager::receiveOneFrame | ( | ) | [protected] |
Definition at line 69 of file VideoManager.cpp.
bool VideoManager::reconnect | ( | ) | [protected] |
Definition at line 255 of file VideoManager.cpp.
bool VideoManager::requestNextImage | ( | ) | [protected] |
Definition at line 303 of file VideoManager.cpp.
bool VideoManager::requestNextImageIfNecessary | ( | ) | [protected] |
Definition at line 198 of file VideoManager.cpp.
bool VideoManager::resume | ( | ) |
Definition at line 482 of file VideoManager.cpp.
bool VideoManager::sendInitSeq | ( | ) | [protected] |
Definition at line 391 of file VideoManager.cpp.
void VideoManager::setDestination | ( | unsigned char * | dst | ) | [inline] |
Definition at line 76 of file VideoManager.h.
void VideoManager::setFrameRate | ( | double | fps | ) |
Definition at line 494 of file VideoManager.cpp.
bool VideoManager::setImageSize | ( | unsigned int | width, |
unsigned int | height | ||
) |
768x576, 384x288, 192x144, 96x72
Definition at line 325 of file VideoManager.cpp.
void VideoManager::setMaxFrameRate | ( | ) |
Definition at line 489 of file VideoManager.cpp.
void VideoManager::setRecordingBasename | ( | const char * | bname | ) |
Definition at line 531 of file VideoManager.cpp.
void VideoManager::setRecordingDestination | ( | const char * | dirname | ) |
Definition at line 526 of file VideoManager.cpp.
void VideoManager::setSignalFunction | ( | SignalF | f, |
void * | arg | ||
) | [inline] |
Definition at line 77 of file VideoManager.h.
void VideoManager::setVerboseLevel | ( | unsigned int | v | ) |
Definition at line 50 of file VideoManager.cpp.
void VideoManager::setVideoOutputColorSpace | ( | JpegReader::ColorSpace | cspace | ) |
Definition at line 521 of file VideoManager.cpp.
void VideoManager::startRecording | ( | ) | [inline] |
Definition at line 65 of file VideoManager.h.
void VideoManager::stopRecording | ( | ) | [inline] |
Definition at line 66 of file VideoManager.h.
void* video_reception_thread | ( | void * | thrarg | ) | [friend] |
Definition at line 145 of file VideoManager.cpp.
void* video_request_thread | ( | void * | thrarg | ) | [friend] |
Definition at line 176 of file VideoManager.cpp.
unsigned char* VideoManager::destination [protected] |
Definition at line 20 of file VideoManager.h.
unsigned int VideoManager::frame [protected] |
Definition at line 25 of file VideoManager.h.
unsigned int VideoManager::height [protected] |
Definition at line 35 of file VideoManager.h.
pthread_mutex_t VideoManager::initMtx [protected] |
Definition at line 31 of file VideoManager.h.
double VideoManager::interImageDelay [protected] |
Definition at line 16 of file VideoManager.h.
JpegReader* VideoManager::jpeg [protected] |
Definition at line 36 of file VideoManager.h.
double VideoManager::lastFrameTimeStamp [protected] |
Definition at line 15 of file VideoManager.h.
double VideoManager::observedFrameRate [protected] |
Definition at line 17 of file VideoManager.h.
bool VideoManager::paused [protected] |
Definition at line 18 of file VideoManager.h.
bool VideoManager::readyToRequest [protected] |
Definition at line 19 of file VideoManager.h.
pthread_t VideoManager::rec_thr_id [protected] |
Definition at line 28 of file VideoManager.h.
VideoGram VideoManager::reception [protected] |
Definition at line 14 of file VideoManager.h.
pthread_t VideoManager::req_thr_id [protected] |
Definition at line 29 of file VideoManager.h.
pthread_cond_t VideoManager::reqCond [protected] |
Definition at line 33 of file VideoManager.h.
pthread_mutex_t VideoManager::reqMtx [protected] |
Definition at line 32 of file VideoManager.h.
bool VideoManager::savestream [protected] |
Definition at line 38 of file VideoManager.h.
SignalF VideoManager::signal [protected] |
Definition at line 26 of file VideoManager.h.
void* VideoManager::signalarg [protected] |
Definition at line 27 of file VideoManager.h.
pthread_mutex_t VideoManager::sockMtx [protected] |
Definition at line 30 of file VideoManager.h.
JpegStreamSaver VideoManager::ssaver [protected] |
Definition at line 37 of file VideoManager.h.
bool VideoManager::terminate [protected] |
Definition at line 23 of file VideoManager.h.
unsigned int VideoManager::verbose [protected] |
Definition at line 22 of file VideoManager.h.
Socket* VideoManager::videosock [protected] |
Definition at line 47 of file VideoManager.h.
unsigned int VideoManager::width [protected] |
Definition at line 35 of file VideoManager.h.