Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Mon 01 Sep 2014, 03:55
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
text2speech german
Moderators: deshlab, Flash, GuestToo, Ian, JohnMurga, Lobster
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [7 Posts]  
Author Message
MU


Joined: 24 Aug 2005
Posts: 13642
Location: Karlsruhe, Germany

PostPosted: Fri 16 Jun 2006, 11:40    Post subject:  text2speech german  

Download (11 MB):
http://dotpups.de/dotpups/Science/txt2speech-german.pup

Then open a console-window, and type:
say "Dieser Synthesizer ist durchaus zum vorlesen längerer Texte geeignet. Er kann auch zählen. 3,14 ist Pi."

Or:
say "inglish sounds olmost as woers as spoken by a riel german" Laughing


To set the speed, type:
sayspeed 10000

Try values between 10000 and 20000.
To set the default (15000) just type
sayspeed

It uses aplay (alsa) for playing, to change that, you would have to modify
/usr/local/bin/txt2speech.sh

I created the dotpup using these instructions:
http://www.linuxwiki.de/SprachAusgabe

Mark

Last edited by MU on Mon 14 Jul 2008, 06:50; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website 
MU


Joined: 24 Aug 2005
Posts: 13642
Location: Karlsruhe, Germany

PostPosted: Fri 16 Jun 2006, 12:11    Post subject:  

uploaded again, the speedsetting did not work.
Mark
Back to top
View user's profile Send private message Visit poster's website 
vabene06

Joined: 25 Apr 2006
Posts: 36

PostPosted: Sat 17 Jun 2006, 05:53    Post subject:  

It is nice.
Ist es mglich, sich eine lngere Textdatei vorlesehen zu lassen?

vabene
Back to top
View user's profile Send private message 
MU


Joined: 24 Aug 2005
Posts: 13642
Location: Karlsruhe, Germany

PostPosted: Sat 17 Jun 2006, 10:37    Post subject:  

yes, to read a longer textfile, run such a command:

say "`cat /etc/puppyversion`"

But it is difficult to understand, because it sounds very monotone.

you could use such a shellscript:

saytext
Code:
#!/bin/bash

say "`cat $1`"


Then you can use it like say:
saytext /etc/puppyversion

It might be worth a try, to test other voices.
Download one of those mentioned here:
http://www.linuxwiki.de/SprachAusgabe

Extract to
/usr/local/txt2speech
Then you should have a new subfolder there like "de2".

To use it instead of de1, edit this line in /usr/local/bin/txt2speech.sh:
VOICE=de1
Set it to
VOICE=de2

Mark
Back to top
View user's profile Send private message Visit poster's website 
vabene06

Joined: 25 Apr 2006
Posts: 36

PostPosted: Sat 17 Jun 2006, 11:27    Post subject:  

Thanx, it works fine.
vabene
Back to top
View user's profile Send private message 
MU


Joined: 24 Aug 2005
Posts: 13642
Location: Karlsruhe, Germany

PostPosted: Sat 17 Jun 2006, 14:24    Post subject:  

here, this is much better:

save it as /usr/local/bin/talktext1

Then make it executable:
chmod 755 /usr/local/bin/talktext1

Code:
#!/usr/bin/puppybasic
include "/usr/lib/wxbasicscript/basefunctions.inc"

say = "say"


thefile = argvtostring()

if left(thefile,3) = "-en" then
  say = "talk"
  thefile = cutleft(thefile , "-en ")
end if



t = readfiletolist(thefile)

for i = 0 to count(t)-1

  t[i] = replace(t[i],"\"" , "\\\"")

  t[i] = replace(t[i],". " , ". . . . ")
  t[i] = replace(t[i],"! " , "! . . . ")
  t[i] = replace(t[i],"? " , "? . . . ")

next

writelisttofile("/tmp/talktext.tmp" , t)
shell(say & " \"`cat /tmp/talktext.tmp`\"")
removefile("/tmp/talktext.tmp")



Then save this text as "/root/test.txt":

Quote:
US-Außenministerin Rice hat Äußerungen der iranischen Regierung über den Vermittlungsvorschlag im Atomstreit begrüßt. Der Optimismus von Deutschlands Außenminister Steinmeier hält sich indes in Grenzen.


important save it as ISO-8859-1, not as UTF-8 Exclamation
There is a small selection for that in the "save as" dialog of leafpad.

Then run:
talktext1 /root/test.txt

Now you really can understand what she says!
Ok, maybe you must listen twice. But it is much better than before, because now you have a pause between each sentence. And you can use Texts, that contain the "-sign, too.

To test it with the english festival:
Use an english text, then run
talktext1 -en /root/test.txt

But that is much more difficult to understand than german. Maybe some more tweaking achieves better results.

Mark

Last edited by MU on Sun 13 Jul 2008, 21:53; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website 
vabene06

Joined: 25 Apr 2006
Posts: 36

PostPosted: Sun 18 Jun 2006, 01:56    Post subject:  

It is ok. It works fine . thanx, vabene
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [7 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0614s ][ Queries: 12 (0.0106s) ][ GZIP on ]