Commit Graph
70 Commits
Author SHA1 Message Date
Juho Hiltunen 2ec4ad38ea Use stressRule instead of stressrule for consistency 2017-12-10 21:05:20 +02:00
Juho Hiltunen 6042eb8d1e Move handling of SetLetterVowel() to language files
Contributes to:
Issue #218, https://github.com/espeak-ng/espeak-ng/issues/218

Changes:
language files have a new keyword letterVowel. It can be a latin alphabet from a-z or a hex value (used by bulgarian).
Errors in parsing the values are only reported, nothing is done about them.

About testing:
I haven't noticed any differences in the output audio with letterVowel set or unset in any tested language. The code seems to work and the correct bits seem to be set, but I don't know how to confirm from the final audio.

TODO:
1. Write better documentation in docs/voices.md
2. The code uses new_translator. Should it use translator instead?
2017-12-10 21:04:36 +02:00
Reece H. Dunn 74f9f5e34b wavegen.c: Fix -Wmissing-prototypes warnings. 2017-10-10 21:37:46 +01:00
Reece H. Dunn dd3df1d0a8 Enable and fix -Wunused-function warnings. 2017-10-05 07:05:47 +01:00
Reece H. Dunn 882c2651e1 Fix setting the default voice from espeak_SetVoiceByProperties. 2017-08-19 12:08:39 +01:00
Reece H. Dunn 16bea7fd0f Don't crash in LoadVoice if langopts is NULL. 2017-08-19 11:44:13 +01:00
Reece H. Dunn 7accbcd498 Only update the sample rate if the mbrola voice was successfully loaded. 2017-05-28 10:41:16 +01:00
Reece H. Dunn e41a78d819 Report the actual error from LoadMbrolaTable when loading the mbrola voice. 2017-05-28 10:38:15 +01:00
Reece H. Dunn 2f8f125c68 Remove voice/language support for alphabet2.
This is not used by any of the espeak-ng voices and languages.
Additionally, this functionality would be superceded by support
for specifying the language used by different scripts in the
language argument on the command line.
2017-05-07 15:10:42 +01:00
Reece H. Dunn 9af96da469 Make the encoding.h API public. 2017-05-02 18:40:16 +01:00
Reece H. Dunn 7c16ac543c Use the text decoder API in readclause.c. 2017-03-31 13:17:37 +01:00
Reece H. Dunn 0b0661cef0 Use the encoding.c tables for 8-bit encodings.
1.  Store the encoding enumeration values in the Translation
    object, instead of the charset table.

2.  Use the encoding.c charset table data instead of the ones
    in translate.c.

3.  Remove the charset language file option -- it is only used
    in the Arabic language file, but is used incorrectly there.

4.  Specify ISO 8859-6 for the 8-bit encoding for Arabic instead
    of UTF-8, so that espeakCHARS_8BIT and espeakCHARS_AUTO work
    correctly for Arabic.
2017-03-31 00:01:14 +01:00
Reece H. Dunn ddc075288c Windows: Fix a crash when building the 'en' voice.
This occurs in ReadVoiceFile (voices.c) when calling isspace to
isolate the attribute name. It happens because the msvc
implementation of isspace asserts that the character is in a valid
range, which fails for non-ASCII characters.

This commit resolves the problem by calling iswspace, which uses
the ucd-tools implementation.
2017-03-19 13:53:14 +00:00
Reece H. Dunn 71c010b712 Remove unused wchar.h and wctype.h includes. 2017-02-10 08:03:40 +00:00
Reece H. Dunn 36a2872b4b Don't allow the gender property to be set in language files (they are only relevant in voice files). 2017-02-05 19:56:07 +00:00
Reece H. Dunn 1c5bbe31a4 Use LookupMnem in ReadVoiceFile when parsing lines. 2017-02-05 19:55:48 +00:00
Reece H. Dunn d30cf6f0d7 Default voices/languages to be male to match the default voice. 2017-02-05 19:08:27 +00:00
Reece H. Dunn f6147085cd Use enumeration constants for the voice gender field values. 2017-02-05 19:06:27 +00:00
Reece H. Dunn 46cd5f48e1 Don't allow 'gender unknown' in voice/language files. 2017-02-05 18:47:31 +00:00
Reece H. Dunn ea365af43c Remove the 'dictdialect' feature. 2017-02-05 17:03:44 +00:00
Reece H. Dunn 6eaf1d2ddc Look in espeak-ng-data/lang for voices.
This is to support splitting language specification (dictionaries)
from voice specification (phon*).
2017-02-04 16:50:57 +00:00
Reece H. Dunn bb7630e4c1 Make len_path_voices a parameter to GetVoices. 2017-02-04 16:44:12 +00:00
Reece H. Dunn 022e4e82dd Don't check if the MBROLA voice data is present on Windows.
With the original eSpeak Windows port, the MBROLA voices had to
be present in an mbrola folder of the espeak-data. This will be
different in espeak-ng, allowing the MBROLA voice files to be
located elsewhere on the system.
2017-02-04 16:34:09 +00:00
Reece H. Dunn df6a2228b7 Use -EISDIR instead of -2 in GetFileLength for directories. 2017-02-04 16:02:56 +00:00
Reece H. Dunn 59ca718d40 Always use 'en' as the default voice/language. 2017-01-19 19:57:06 +00:00
Valdis Vitolins 640f0d8160 Typo fixes 2017-01-13 21:19:59 +02:00
Reece H. Dunn 9bb9e98f84 Don't exclude the test voice directory.
This directory is no longer available, so the check is now
redundant.
2016-12-29 15:06:55 +00:00
Reece H. Dunn 4920ecc79c Move espeak-data to espeak-ng-data to avoid conflicting with upstream espeak. 2016-09-10 09:44:13 +01:00
Ondřej Lysoněk 3817ee1e16 Moved speak_lib.h to espeak-ng directory
Moved include/espeak/speak_lib.h to include/espeak-ng/speak_lib.h and
created a symlink from the original location.
2016-08-28 10:57:10 +01:00
Reece H. Dunn aaf52c3a78 Remove unused variables. 2016-06-05 08:52:38 +01:00
Reece H. Dunn b620f42775 voices: support a status annotation in voice files 2016-05-21 21:29:39 +01:00
Reece H. Dunn 7e3e2c3854 voices: support a maintainer annotation in voice files 2016-05-21 21:16:55 +01:00
Reece H. Dunn 4cde8b6d13 option_quiet is no longer used (always set to 0), so remove it 2016-02-06 10:45:32 +00:00
Reece H. Dunn 211f103a69 Perform case insensitive comparisons for matching voice names. 2016-02-01 18:37:06 +00:00
Reece H. Dunn e8015df0f8 Remove the additional LoadVoice search heuristics.
These heuristics were designed to guess the location of the voice
files without searching the voice list. The heuristics are very
implementation dependent, and easily break when voices move around.
The voices are still found correctly, so these heuristics are
redundant.
2016-01-23 14:50:43 +00:00
Reece H. Dunn c0d79709c4 Fix Windows includes (don't rely on speech.h). 2016-01-16 18:19:39 +00:00
Reece H. Dunn 96c43f3eb2 Clean up the include files to make them consistent. 2016-01-16 17:54:39 +00:00
Reece H. Dunn 142063f1e6 Remove a GCC incompatible pointer conversion warning in voices.c. 2016-01-12 21:51:44 +00:00
Reece H. Dunn 4ac6355834 Fix the realloc usage of voices in espeak_ListVoices(voices.c) [msvc /analyze] 2016-01-12 21:46:08 +00:00
Reece H. Dunn 11101806ce Support building espeak-ng.exe with Visual C++. 2016-01-09 13:32:16 +00:00
Reece H. Dunn 9c7179189b Add a stdint.h compatibility shim. 2016-01-09 13:09:50 +00:00
Reece H. Dunn d4dd2cacca Fix the voice_dir logic in LoadVoice(voices.c) [clang scan-build] 2016-01-06 20:27:29 +00:00
Reece H. Dunn cb3699746c Check the return value of sscanf in LoadVoice(voices.c) [clang scan-build] 2016-01-06 20:22:58 +00:00
Reece H. Dunn bc8297bf3c Remove a dead assignment in LoadVoice(voices.c) [clang scan-build] 2016-01-06 20:19:31 +00:00
Reece H. Dunn 72db232ec3 Move include/espeak{-ng => }/speak_lib.h. 2016-01-04 19:45:23 +00:00
Reece H. Dunn fb99a17b7f new_translator may be NULL when processing the charset command [clang scan-build] 2016-01-03 12:26:38 +00:00
Reece H. Dunn 6aeb5a26f0 Replace the remaining espeak_ERROR code usage with espeak_ng_STATUS. 2016-01-02 19:24:39 +00:00
Reece H. Dunn e69f0f41f0 Make LoadMbrolaTable return espeak_ng_STATUS. 2016-01-02 18:59:18 +00:00
Reece H. Dunn df170d1c48 Create an espeak-ng version of espeak_SetVoiceBy(Name|Properties). 2016-01-02 18:42:26 +00:00
Reece H. Dunn c2811d074e Make LoadPhData return an espeak_ng_STATUS code. 2016-01-01 13:17:11 +00:00