Showing
2 changed files
with
14 additions
and
1 deletions
... | @@ -59,6 +59,8 @@ | ... | @@ -59,6 +59,8 @@ |
59 | <workItem from="1574342689824" duration="11000" /> | 59 | <workItem from="1574342689824" duration="11000" /> |
60 | <workItem from="1574396813813" duration="10012000" /> | 60 | <workItem from="1574396813813" duration="10012000" /> |
61 | <workItem from="1574494473410" duration="2577000" /> | 61 | <workItem from="1574494473410" duration="2577000" /> |
62 | + <workItem from="1574565997693" duration="30000" /> | ||
63 | + <workItem from="1574569996051" duration="559000" /> | ||
62 | </task> | 64 | </task> |
63 | <servers /> | 65 | <servers /> |
64 | </component> | 66 | </component> | ... | ... |
... | @@ -147,11 +147,22 @@ function handleEvent(event) { | ... | @@ -147,11 +147,22 @@ function handleEvent(event) { |
147 | var objBody = JSON.parse(response.body); | 147 | var objBody = JSON.parse(response.body); |
148 | result.text = objBody.message.result.translatedText; | 148 | result.text = objBody.message.result.translatedText; |
149 | //번역된 문자 audio로 저장 | 149 | //번역된 문자 audio로 저장 |
150 | + if(options.form.target=='ko'){ | ||
150 | let audio_options={ | 151 | let audio_options={ |
151 | 'Text': result.text, | 152 | 'Text': result.text, |
152 | 'OutputFormat': 'mp3', | 153 | 'OutputFormat': 'mp3', |
153 | - 'VoiceId':'Amy' | 154 | + 'VoiceId':'Amy', |
155 | + "LanguageCode":'ko-KR' | ||
154 | }; | 156 | }; |
157 | + } | ||
158 | + else if(options.form.target=='en'){ | ||
159 | + let audio_options={ | ||
160 | + 'Text': result.text, | ||
161 | + 'OutputFormat': 'mp3', | ||
162 | + 'VoiceId':'Amy', | ||
163 | + "LanguageCode":'en-US' | ||
164 | + }; | ||
165 | + } | ||
155 | Polly.synthesizeSpeech(audio_options, (err, data) => { | 166 | Polly.synthesizeSpeech(audio_options, (err, data) => { |
156 | console.log("check"); | 167 | console.log("check"); |
157 | if (err) { | 168 | if (err) { | ... | ... |
-
Please register or login to post a comment