Commit graph

19 commits

Author SHA1 Message Date
William Hubbs
3b4b6d0cbc change code to use allocMem wrapper for memory allocation
One of the new string handling routines is a wrapper for allocating
memory. This commit changes the rest of the code to take advantage of
that wrapper.
2011-05-06 23:08:33 -05:00
William Hubbs
701074fd96 go back to just using a makefile
The reason I went to autotools was the multiple sound systems, but since
we are now just using espeak's audio processing we can go back to a more
simple build system.
2011-03-06 13:09:42 -06:00
William Hubbs
056dcf70fe convert to autotools 2010-05-04 22:55:13 -05:00
William Hubbs
739e074072 reworked the queue_remove function
Now, when queue_remove is called, it returns the pointer to the data of
the first entry in the queue and removes the entry.
2009-06-30 20:15:20 -05:00
William Hubbs
0a9a8cce9b small style changes 2009-06-30 08:15:27 -05:00
Christopher Brannon
40479540b4 Fix a memory leak.
If we fail to add entries to the queue in queue_add_cmd or
queue_add_text, properly free the entry.
2009-06-29 18:42:25 -05:00
Christopher Brannon
31ad5f04ca Completely data-agnostic queue functions.
The functions in queue.c no longer use static variables.  We can now use
them for multiple queues, if necessary.
2009-06-29 18:07:18 -05:00
William Hubbs
a8cad20de8 more multithreading work
Rearranged the queue handling code so that queue.c is generic.  Also
rearranged several functions in the threads.
2009-06-25 09:05:21 -05:00
William Hubbs
42c3f76a08 moved include for pthread.h to espeakup.h 2009-06-25 01:21:44 -05:00
William Hubbs
af5717b8cb moved queue_add_xxx functions to softsynth thread 2009-06-24 22:23:10 -05:00
Christopher Brannon
d82bfcd09c Make one thread responsible for handling espeak interaction.
Most of the idea for this change came from William:
Renamed queue_runner to espeak_thread.  Moved espeak initialization
and termination to espeak_thread.  The while loops that process
the queue now use the variable should_run.
2009-06-24 22:11:52 -05:00
William Hubbs
f58d9984ce Now the queue runner/softsynth handler clears the queue
Thanks to Chris Brannon for the patch.
2009-06-24 16:59:23 -05:00
William Hubbs
24e7d667bc queue fixes
This adds retry processing back to the queue functions.  queue_remove
should only be called after the head entry on the queue is processed
successfully.
2009-06-23 20:34:04 -05:00
William Hubbs
d7c81f5117 indentation fixes 2009-05-29 23:17:28 -05:00
Christopher Brannon
3ddbb94e37 multithreading
Make espeakup a multi-threaded program.  One thread reads from the softsynth
device, queuing text and synthesis commands.  The other thread processes
items from the queue.
2009-05-29 20:00:06 -05:00
William Hubbs
bbf77d918d Cleaned up warnings and adjusted CFLAGS
This commit cleans up warnings and adjusts CFLAGS.  Thanks to
samuel.thibault@ens-lyon.org.
2009-03-03 18:02:19 -06:00
William Hubbs
36b05aec41 Added support for the punctuation command from speakup 2008-10-18 16:56:47 -05:00
William Hubbs
5ddeb1e978 indentation fixes 2008-09-01 12:50:16 -05:00
William Hubbs
655894ee2a added queueing support
I have added queueing support so that when we read from the softsynth we
can put the text and commands we have read into a queue.  This will
allow us to retry calling espeak_synth() if we fill espeak's internal
buffer.
2008-08-16 19:48:40 -05:00