help with get request

Get help using Construct 2

Post » Thu Jul 26, 2012 12:17 pm

I'm trying to use this url http://speechutil.com/convert/ogg?text='Hello Dolly!!!' from speechutil.com to get some text to speech functionality, I'm using the ajax object but can't get it to work...

Any suggestions?
B
6
S
1
Posts: 8
Reputation: 591

Post » Thu Jul 26, 2012 3:59 pm

I doubt your gonna get anythin back from the request cause it creates a sound file. Thats not somethin you can pull into c2. The ajax object is basically used to request pages with the intent that the page requested echos data. That echoed data will then be stored in AJAX.LastData

Its meant mainly for text. The only way you could get the sound file across it is to somehow echo the binary data of the sound file then save that to the computer receiving it and THEN play it.

Either that or someone makes a way to play streaming sound from a url similar to how you can load images from url
B
13
S
5
G
2
Posts: 306
Reputation: 3,262

Post » Thu Jul 26, 2012 4:04 pm

I think this should be possible with a custom made Plugin (maybe a behaviour for the audio plugin?), as HTML5 allows to stream music from URLs:
http://dev.w3.org/html5/markup/audio.html
B
42
S
9
G
6
Posts: 437
Reputation: 5,626


Return to How do I....?

Who is online

Users browsing this forum: Vallar and 18 guests