# include "config.h"
#endif
-#include <pthread.h>
+#include <glib.h>
#include "misc.h"
#include "decoder.h"
rd3 = (vbi3_raw_decoder *) rd->pattern;
n_lines = rd->count[0] + rd->count[1];
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
n_lines = vbi3_raw_decoder_decode (rd3, out, n_lines, raw);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return n_lines;
}
rd3 = (vbi3_raw_decoder *) rd->pattern;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
if ((rd->start[0] == start[0])
&& (rd->start[1] == start[1])
&& (rd->count[0] == (int) count[0])
&& (rd->count[1] == (int) count[1])) {
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return;
}
#endif
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
}
/**
rd3 = (vbi3_raw_decoder *) rd->pattern;
service_set = services;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
service_set = vbi3_raw_decoder_remove_services (rd3, service_set);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return service_set;
}
service_set = services;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
service_set = vbi_sampling_par_check_services
((vbi_sampling_par *) rd, service_set, strict);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return (unsigned int) service_set;
}
rd3 = (vbi3_raw_decoder *) rd->pattern;
service_set = services;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
vbi3_raw_decoder_set_sampling_par (rd3, (vbi_sampling_par *) rd, strict);
service_set = vbi3_raw_decoder_add_services (rd3, service_set, strict);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return service_set;
}
service_set = services;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
service_set = vbi_sampling_par_from_services
(unsigned int *) max_rate, videostd_set, service_set);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
return (unsigned int) service_set;
}
rd3 = (vbi3_raw_decoder *) rd->pattern;
- pthread_mutex_lock (&rd->mutex);
+ g_mutex_lock (&rd->mutex);
{
vbi3_raw_decoder_reset (rd3);
}
- pthread_mutex_unlock (&rd->mutex);
+ g_mutex_unlock (&rd->mutex);
}
/**
vbi3_raw_decoder_delete (rd3);
- pthread_mutex_destroy (&rd->mutex);
+ g_mutex_clear (&rd->mutex);
CLEAR (*rd);
}
CLEAR (*rd);
- pthread_mutex_init (&rd->mutex, NULL);
+ g_mutex_init (&rd->mutex);
rd3 = vbi3_raw_decoder_new ( /* sampling_par */ NULL);
assert (NULL != rd3);