summaryrefslogtreecommitdiff
path: root/recordmydesktop/src
diff options
context:
space:
mode:
authorenselic <enselic@f606c939-3180-4ac9-a4b8-4b8779d57d0a>2008-09-14 07:36:57 +0000
committerenselic <enselic@f606c939-3180-4ac9-a4b8-4b8779d57d0a>2008-09-14 07:36:57 +0000
commit0d45a511b9532e2d5b82625a448ad4412f0ee7b2 (patch)
tree35c0a7b640a0f85c22cf0d9e883e5f91eb5d6fb7 /recordmydesktop/src
parent172b458884bec3c8379c9951de96a9e3b21ca770 (diff)
src/rmdtypes.h: Made ProgData::capture_busy and encoder_busy booleans.
src/get_frame.c src/initialize_data.c src/encode_image_buffer.c: Adapt. git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@542 f606c939-3180-4ac9-a4b8-4b8779d57d0a
Diffstat (limited to 'recordmydesktop/src')
-rw-r--r--recordmydesktop/src/encode_image_buffer.c4
-rw-r--r--recordmydesktop/src/get_frame.c4
-rw-r--r--recordmydesktop/src/initialize_data.c4
-rw-r--r--recordmydesktop/src/rmdtypes.h4
4 files changed, 8 insertions, 8 deletions
diff --git a/recordmydesktop/src/encode_image_buffer.c b/recordmydesktop/src/encode_image_buffer.c
index 1fa1176..fe57007 100644
--- a/recordmydesktop/src/encode_image_buffer.c
+++ b/recordmydesktop/src/encode_image_buffer.c
@@ -38,7 +38,7 @@ void *EncodeImageBuffer(ProgData *pdata){
&pdata->img_buff_ready_mutex);
pthread_mutex_unlock(&pdata->img_buff_ready_mutex);
pdata->th_enc_thread_waiting=0;
- pdata->encoder_busy = 1;
+ pdata->encoder_busy = TRUE;
if (pdata->paused) {
pthread_mutex_lock(&pdata->pause_mutex);
pthread_cond_wait(&pdata->pause_cond, &pdata->pause_mutex);
@@ -62,7 +62,7 @@ void *EncodeImageBuffer(ProgData *pdata){
pdata->avd+=pdata->frametime;
}
}
- pdata->encoder_busy = 0;
+ pdata->encoder_busy = FALSE;
}
//last packet
pdata->th_encoding_clean=1;
diff --git a/recordmydesktop/src/get_frame.c b/recordmydesktop/src/get_frame.c
index 46d0a7b..6648996 100644
--- a/recordmydesktop/src/get_frame.c
+++ b/recordmydesktop/src/get_frame.c
@@ -440,7 +440,7 @@ void *GetFrame(ProgData *pdata){
//switch back and front buffers (full_shots only)
if(d_buff)
img_sel=(img_sel)?0:1;
- pdata->capture_busy = 1;
+ pdata->capture_busy = TRUE;
BRWinCpy(&temp_brwin,&pdata->brwin);
@@ -634,7 +634,7 @@ void *GetFrame(ProgData *pdata){
pthread_mutex_lock(&pdata->img_buff_ready_mutex);
pthread_cond_broadcast(&pdata->image_buffer_ready);
pthread_mutex_unlock(&pdata->img_buff_ready_mutex);
- pdata->capture_busy = 0;
+ pdata->capture_busy = FALSE;
}
if(!pdata->args.noframe){
diff --git a/recordmydesktop/src/initialize_data.c b/recordmydesktop/src/initialize_data.c
index 9356f6a..c81bf6c 100644
--- a/recordmydesktop/src/initialize_data.c
+++ b/recordmydesktop/src/initialize_data.c
@@ -94,8 +94,8 @@ int InitializeData(ProgData *pdata,
pdata->pause_state_changed = FALSE;
pdata->frames_total = 0;
pdata->frames_lost = 0;
- pdata->encoder_busy = 0;
- pdata->capture_busy = 0;
+ pdata->encoder_busy = FALSE;
+ pdata->capture_busy = FALSE;
if(!pdata->args.nosound){
if(!pdata->args.use_jack){
diff --git a/recordmydesktop/src/rmdtypes.h b/recordmydesktop/src/rmdtypes.h
index cdd4fbf..5495a6b 100644
--- a/recordmydesktop/src/rmdtypes.h
+++ b/recordmydesktop/src/rmdtypes.h
@@ -355,8 +355,8 @@ struct _ProgData {
//used to determine frame drop which can
//happen on failure to receive a signal over a condition variable
- int capture_busy,
- encoder_busy;
+ boolean capture_busy,
+ encoder_busy;
pthread_mutex_t pause_mutex;
pthread_mutex_t time_mutex;
© All Rights Reserved