|
| Inicio → WINDEV 2025 → Sauvegarde de fichier .mp3 à partir de l'API Google TextToSpeech |
| Sauvegarde de fichier .mp3 à partir de l'API Google TextToSpeech |
| Iniciado por medmouden, 17,may. 2020 17:41 - 2 respuestas |
| |
| | | |
|
| |
| Publicado el 17,mayo 2020 - 17:41 |
Bonjour à tous, Le sujet avait déjà été lancé depuis quelques années, mais il n'y a pas eu de suite. 1. Comment encoder en base64, le resultat de la réponse de l'api Google TextToSpeech. 2. Dans la doc , le fichier .txt généré peut être converti en .mp3. Quel est le code en windev?
Text-to-Speech allows you to convert words and sentences into base64 encoded audio data of natural human speech. You can then convert the audio data into a playable audio file like an MP3 by decoding the base64 data.
https://cloud.google.com/text-to-speech/docs/create-audio…
Merci d'avance pour votre aide si vous avez un bout de code.
Bons développements |
| |
| |
| | | |
|
| | |
| |
Miembro registrado 1.002 mensajes |
|
| Publicado el 17,mayo 2020 - 19:23 |
Bonjour,
Comme ca je dirai, si la reponse du webservice est bien "{audioContent: etc..."
MonfichierMP3 est une chaîne ANSI = fRepExe() + "Result.mp3" fCrée(MonfichierMP3) MareponseTextToSpeech est un variant = jsonversvarian("{audioContent: NExAASCCIIAAhEAGAAEMW4kAYPnwwIKw/BBTpwTvB+IAxIfghUfW..}") fSauveBuffer(MonfichierMP3,Decode(MareponseTextToSpeech.audioContent, encodeBASE64))
jordan |
| |
| |
| | | |
|
| | |
| |
| Publicado el 17,mayo 2020 - 21:12 |
Merci bcp Jordan. ça fonctionne. Mehdi |
| |
| |
| | | |
|
| | | | |
| | |
|