summaryrefslogtreecommitdiff
path: root/recordmydesktop/src
diff options
context:
space:
mode:
Diffstat (limited to 'recordmydesktop/src')
-rw-r--r--recordmydesktop/src/encode_image_buffer.c2
-rw-r--r--recordmydesktop/src/encode_sound_buffer.c4
-rw-r--r--recordmydesktop/src/recordmydesktop.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/recordmydesktop/src/encode_image_buffer.c b/recordmydesktop/src/encode_image_buffer.c
index 76c4126..bc80abe 100644
--- a/recordmydesktop/src/encode_image_buffer.c
+++ b/recordmydesktop/src/encode_image_buffer.c
@@ -17,7 +17,7 @@ void *EncodeImageBuffer(void *pdata){
pthread_mutex_unlock(&((ProgData *)pdata)->yuv_mutex);
theora_encode_packetout(&((ProgData *)pdata)->enc_data->m_th_st,0,&((ProgData *)pdata)->enc_data->m_ogg_pckt1);
ogg_stream_packetin(&((ProgData *)pdata)->enc_data->m_ogg_ts,&((ProgData *)pdata)->enc_data->m_ogg_pckt1);
- avd+=((ProgData *)pdata)->frametime*2*((ProgData *)pdata)->args.channels;
+ ((ProgData *)pdata)->avd+=((ProgData *)pdata)->frametime*2*((ProgData *)pdata)->args.channels;
}
//last packet
if(theora_encode_YUVin(&((ProgData *)pdata)->enc_data->m_th_st,&((ProgData *)pdata)->enc_data->yuv)){
diff --git a/recordmydesktop/src/encode_sound_buffer.c b/recordmydesktop/src/encode_sound_buffer.c
index 1c42ae8..03b4043 100644
--- a/recordmydesktop/src/encode_sound_buffer.c
+++ b/recordmydesktop/src/encode_sound_buffer.c
@@ -25,7 +25,7 @@ void *EncodeSoundBuffer(void *pdata){
((ProgData *)pdata)->sound_buffer=((ProgData *)pdata)->sound_buffer->next;
pthread_mutex_unlock(&((ProgData *)pdata)->sound_buffer_mutex);
- if (avd>0){
+ if (((ProgData *)pdata)->avd>0){
vorbis_buffer=vorbis_analysis_buffer(&((ProgData *)pdata)->enc_data->m_vo_dsp,sampread);
for(i=0;i<sampread;i++){
@@ -45,7 +45,7 @@ void *EncodeSoundBuffer(void *pdata){
while(vorbis_bitrate_flushpacket(&((ProgData *)pdata)->enc_data->m_vo_dsp,&((ProgData *)pdata)->enc_data->m_ogg_pckt2))
ogg_stream_packetin(&((ProgData *)pdata)->enc_data->m_ogg_vs,&((ProgData *)pdata)->enc_data->m_ogg_pckt2);
}
- avd-=((ProgData *)pdata)->periodtime;
+ ((ProgData *)pdata)->avd-=((ProgData *)pdata)->periodtime;
}
free(buff);
}
diff --git a/recordmydesktop/src/recordmydesktop.c b/recordmydesktop/src/recordmydesktop.c
index e438f7f..89f9892 100644
--- a/recordmydesktop/src/recordmydesktop.c
+++ b/recordmydesktop/src/recordmydesktop.c
@@ -91,7 +91,7 @@ int main(int argc,char **argv){
pthread_cond_init(&pdata.image_buffer_ready,NULL);
pthread_cond_init(&pdata.sound_buffer_ready,NULL);
pthread_cond_init(&pdata.sound_data_read,NULL);
- pdata.list_selector=Paused=Aborted=avd=0;
+ pdata.list_selector=Paused=Aborted=pdata.avd=0;
pdata.running=1;
time_cond=&pdata.time_cond;
pause_cond=&pdata.pause_cond;
© All Rights Reserved