I have several Gtk3 apps that I sometimes display in a browser using Broaday.
When running an app on the desktop (Linux in my case), it plays sound by running Sox's "play" command. This obviously won't work for Broadway.
Is there any way to pass audio data to broadwayd (or tell it to play a file) so it the browser will play the sound?
My code is Perl, but I'm open to suggestions in any language.
Related
If you are familiar with scratch, you'll know that Scratch 3 was built to support mobile.
Javascript audio isn't working on mobile devices shows that mobile doesn't support auto playback of audio
Scratch seems to play audio without a problem...
Does anyone know the secret behind Scratch mobile audio playing capabilities? (share pieces of code which scratch uses to play audio on mobile)
(Incase you're wondering why I need to know this, I need to use it on my website)
Read the answer carefully.
Some mobile browsers support automatic playback of audio, but ios, chrome and others require interactive actions to trigger the sound playback.You can try working with the mute attribute..
Scratch can't play sounds automatically. You have to click the Start button on any project. By "interactive actions" they mean clicks, scroll etc,.
I want to play two audio files simultaneously in WP8 from within the same app:
The first one will be launched by "BackgroundAudioPlayer.Instance.Play();".
The second one will be launched by an HTML5 "audio" element within a Html file of the app.
The scenario would be something like this:
When the user launches the app, the background music starts playing.
When the user goes to a particular Html page of the app, its associated music starts playing.
When the user switches the app or locks the screen, the music of that Html page stops, however, the background music keeps on playing until the app is closed.
When the user comes back to that Html page again, its associated music starts playing along with the background music.
Appreciate your suggestions on this.
Thanks.
Together, we have tested a very simple App trying to play simultanously two audio files. The App worked like this:
Play button has started audio file via BAP
then we have navigated in WebBrowser to a page (located in IsolatedStorage) where there was an audio element
and we have pushed play button in WebBrowser (still BAP playing in the background)
It turned out that WebBrowser uses BAP as a player, so after we have pressed the button, our poor BAP playing in the background was terminated and replaced with new fresh one from WebBrowser.
It means that our magnificent idea and superb plan had withered on the vine.
So crap....
You'd need to build a player in your app so it could run simultaneously to the native one.
This explains why you cant run a gif and play music simultaneously.
In short, I have to play RTSP on a Google TV device (Sony nsz-gs7). How can I do it?
Things I tried:
Use NDK to compile ffmpeg, then ffmpeg converts rtsp to udp etc. - Fails because NDK is not supported in Google TV (see: https://developers.google.com/tv/faq#ndk). This method uses ffmpeg as library.
Put ffmpeg executable (compiled with NDK) in an application, then call the app from command line. (see: http://gimite.net/en/index.php?Run%20native%20executable%20in%20Android%20App - first method). I can deploy executable and set its permissions, but cannot execute it; i get "not found" error (its path is correct). If only I could run an executable file in Google TV, the problem would be solved, I think.
Tried to display in VideoView, like Google TV VideoView playing YouTube rtsp videos, it didn't work either.
These approaches all work on Android phones, but I couldn't make them work on Google TV.
Any tips for displaying RTSP or running executable files? Or do I have to wait for NDK support?
Update: If there is an application which can play RTSP streams, we can also use it as a temporary fix.
The current version of Google TV is based on FFMpeg internally and is supposed to play RTSP content of course, if you try that example, you'll want to refresh the url for the RTSP content as YouTube doesn't keep them live long. Since RTSP is a transport format, not a codec, you might want to say what your encoding is.
That said, I've never made RTSP work myself - so I'm not speaking from experience, but I do trust my colleague Shawn who wrote the answer to the link above.
One of the features we announced at Google I/O 2012 was the ability to write your own transport stream and codec's in Java. That software is currently on the LG and will be on most of the others in the next few months.
If your need is urgent write me at Google or on Google+.
I'm building an app that uses AVAudioPlayer and MPMoviePlayerController. The sound works perfectly on the simulator. I know sound works on my phone because other apps play sound just fine (like this one used to). When I start the video, I hear about 0.2s of the background music that's supposed to be playing. I'm getting no errors.
I don't even know where to start on this one. Any idea?
I was getting the "occasional" blip of sound in my app, so I assumed my volume was fine. It turns out that my phone was switched to vibrate aka silent. I flipped the switch back and viola.
The new question is: Do I feel like a moron? Yes I do.
** EDIT **
I stumbled upon the idea to check the switch when I read an article on Understanding the Side Switch
Play Apple's .caf audio file on a webserver? I have .caf audio files (Apple's open audio format) stored on my webserver and want to play them from a web browser on any O/S.
I understand, this doesn't seem like the solution you're looking for, but...
Several weeks ago we faced the same problem. We have several clients which are posting audio files to the web site from theirs iPhones, and we need to play audios on the web site.
But we didn't find any suitable flash player with .caf format support.
So we decided to convert .caf to .mp3 on the server through the ffmpeg.exe utility.
Happily, there a lot of flash players with .mp3 support.
Now I have not tried this... but...
This website:
http://modmyi.com/forums/skinning-themes-discussion/1769-how-do-i-create-caf-file.html
Seems to suggest that .CAF and .AIF may work interchangeably (It suggests that to convert to .CAF you convert to .AIF` and then rename the file).
Have you tried renaming it to .AIF and trying to play in a flash/java browser player? Alternatively just send it as a stream to the web-browser and let the client OS work out what to do with it (Like quicktime running inside the browser).
Let me know how it goes.