diff options
author | iovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a> | 2007-12-02 09:07:24 +0000 |
---|---|---|
committer | iovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a> | 2007-12-02 09:07:24 +0000 |
commit | 86303ab2561c8f53ee41a7a71d673da2086f9833 (patch) | |
tree | 6db4801da5b29083e767c63182666f91d4394665 /recordmydesktop/include | |
parent | 22ee15e51f6d72560af37fad744662161e284eb9 (diff) |
include/rmdfunc.h: removed SetExpired & CancelTimer, added rmdTimer
include/rmdtypes.h: pdata->timer_alive
src/Makefile.am: added rmd_timer in sources
src/rmd_timer.c: new thread that handles timing
src/register_callbacks.c: removed SetExpired & CancelTimer
src/rmdthreads.c: new timing setup(signal-sleep-loop thread, instead of setitimer &sigaction)
git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@452 f606c939-3180-4ac9-a4b8-4b8779d57d0a
Diffstat (limited to 'recordmydesktop/include')
-rw-r--r-- | recordmydesktop/include/rmdfunc.h | 24 | ||||
-rw-r--r-- | recordmydesktop/include/rmdtypes.h | 1 |
2 files changed, 14 insertions, 11 deletions
diff --git a/recordmydesktop/include/rmdfunc.h b/recordmydesktop/include/rmdfunc.h index dad87dd..f230287 100644 --- a/recordmydesktop/include/rmdfunc.h +++ b/recordmydesktop/include/rmdfunc.h @@ -44,6 +44,16 @@ void *PollEvents(ProgData *pdata); /** +* Loop ,signal timer cond var,sleep-\ +* ^ | +* |________________________________/ +* +* +* \param pdata ProgData struct containing all program data +*/ +void *rmdTimer(ProgData *pdata); + +/** * Retrieve frame form xserver, and transform to a yuv buffer, * either directly(full shots) or by calling UpdateImage. * \param pdata ProgData struct containing all program data @@ -113,13 +123,6 @@ int CollideRects(WGeometry *wgeom1, WGeometry **wgeom_return, int *ngeoms); -/** -* Broadcast time condition variable, increment frame count. -* -* \param signum Number of signal received(unused, always SIGALRM) -* -*/ -void SetExpired(int signum); /** * Set up all callbacks and signal handlers @@ -445,10 +448,6 @@ void *LoadCache(ProgData *pdata); */ void SyncEncodeImageBuffer(ProgData *pdata); -/** -* Stop the timer -*/ -void CancelTimer(void); /** * As EncodeSoundBuffer, only with the assumption that @@ -791,6 +790,9 @@ void rmdDrawFrame(Display *dpy, Window win, int width, int height); + + + #endif diff --git a/recordmydesktop/include/rmdtypes.h b/recordmydesktop/include/rmdtypes.h index 317e8c5..d7096ba 100644 --- a/recordmydesktop/include/rmdtypes.h +++ b/recordmydesktop/include/rmdtypes.h @@ -332,6 +332,7 @@ typedef struct _ProgData{ v_encoding_clean, // >> >> v_enc_thread_waiting, //these indicate a wait th_enc_thread_waiting, //condition on the cond vars. + timer_alive, //determines loop of timer thread hard_pause, //if sound device doesn't support pause //we have to close and reopen avd; //syncronization among audio and video |