I'm using mergAV to record video on a LiveCode project for iOS. All works fine but when I play an audio mergAVCamSet stops to work and seems it freezes. Is there a way to play audio and have mergAVCamSet continue to work or the two operations collide?
you need to set the audio category to play and record try:
mergAVAudioSessionSetCategory "play and record",false,false,false,true
Note the true at the end there toggles whether the audio will come out of the speaker instead of the receiver.
Related
I've a small Extension which keeps checking for some data on a website.
On specific event it plays a sound file using:
document.getElementById("audio-beep1").play();
However practically this page isn't the foreground page since I'll be working on some other tab so this sound does not play even though event is detected.
So as I click this tab - sound plays.
Is there any way the sound will play on event even if the tab isn't the foreground one?
Google added an update in the past ~6 months or so, a The Great Suspender knockoff called "Tab Freezing" and "Tab Discarding."
That's why you can't play audio in a background tab. Google has suspended the tab without telling you. It's also why the second you click the tab, it starts playing the audio -- the tab is unfrozen, and re-loaded. This is proving to be a nightmare for one of my clients, as they use Incontact MAX, and if Chrome gets a chance, it simply wrecks the VOIP system.
I do not have a solution for you. Google, in their great and unending wisdom, decided this feature does not need any ability to be configured, disabled, or anything of the sort. Nor did they ask you if you wanted this function to be enabled. Truth be told, they appear to be very embarrassed about the unholy amounts of RAM that Chrome uses, and this is their kludge filled workaround.
(You were once able to disable this feature in chrome://flags but they have removed it from said window, and did not add it to the settings menu.)
And no, telling Chrome not to auto discard in chrome://discards does not actually stop it from doing this.
One suggestion I've heard is looping an audio file that is either not making any noise or so quiet it cannot be heard -- like a 1 second loop of dead air. This might trick Chrome into not freezing or discarding the tab, as it's actively playing audio. No idea if this will work. Another I'm planning to test out is using The Great Suspender on the background tab, and seeing if that prevents Google's thing from working.
Playing sound may do the trick, as tab playing sound is an active tab - but it's an ugly hack and consumes resources unnecessary.
Apparently as of now (12.07.2021) you can Disable tab freezing by this setting: chrome://flags/#calculate-native-win-occlusion
Set it to Disabled and tabs freezing should not happen any more. Here is a source
I have been trying to build a TV application, using an SD.
I have got features like image gallery, video player running,
However, I also wanted to add a virtual on-screen keyboard that works with up-down left-right arrow keys. Can somebody help me with how to get started?
When I wanted to do this with my Vestel (Polaroid Branded) smart TV, which uses "Opera for TV devices" as it's HbbTV browser, I found that I didn't need to.
I simply just used HTML text fields and input types where needed, and as soon as I clicked into them, the browser/OS kernel popped up an onscreen keyboard that was built in for me.
However, I did do some research to see if I needed it, and on some devices you do, whilst I never actually implemented it (My app was just for my own use) the "BBC Television Application Layer" (TAL for short) : https://github.com/bbc/tal had pretty good keyboard support.
Another one that might be worth looking at is "Mautilus SDK" : https://github.com/mautilus/sdk
Be aware though, both are horribly convoluted and use quite complex code where it's really not needed.
I'm trying to play a sound file with python. But when i use the os.system (path\audio.mp3) this opens windows media player and plays the file. Is there a way to make it not open the window but still play the sound?
I've also tried using sound libraries to play the sound like pyaudio to no succes.
I'm trying to make an application, media player using mplayer slave mode.
Any clue about switching VCD Karaoke channel (left and right) on the fly, while
the video is playing on the mplayer-slave mode?
Thanks.
[SOLVED]
switching audio track with
LEFT echo "af pan=2:1:1:0:0" > slave_fifo_file
RIGHT echo "af pan=2:0:0:1:1" > slave_fifo_file
I also hard to find this solution and finally found that
af_add pan=2:1:1:0:0
af_add pan=2:0:0:1:1
is working for changing audio channel Left to Right for VCD karaoke channels.
I hope this will help you developing your Karaoke software.
I developed basic music player using mplayer and VB.NET. If you are interested please tell me.
Recently I have a problem with playing my soundeffects using CocosDenshion. The sound is playing on the iPhone Simulator, but not on my own device. I am not sure what I am doing wrong. Off course I checked if my speakers are still working, but they do while using other apps or the iPod Library.
I just use this simple code:
[[SimpleAudioEngine sharedEngine] playEffect:#"button.wav"];
I double checked the name of the file and it indeed is button.wav.
I hope someone can help me out.
I had the same problem recently and I've figured it out.
I' m using Xcode 4.3.2 and there seems to be a bug.
Not all resources you add (drag) to the project are by default added to the target.
When you add a resource, make sure that (apart from checking the copy items into destination checkbox) you also check the add to target checkbox.
You can check if the resources has been added to the bundle by clicking on the target icon. In the Build Phases tab, check if the sound files are included in the Copy Bundle Resources.
If not, add them manually (+add target)
You might try preloading the sound effects, at some earlier point in the program, as otherwise it has to load the sound effect before it can play it. You could create a splashScreen scene that is the first scene and loads all your assets and then transitions to the first "actual" scene.
SimpleAudioEngine *engine = [SimpleAudioEngine sharedEngine];
[engine preloadEffect:#"Example-Sound.caf"];
Not sure whether it is the case here, but you should keep in mind that if your file name is "Button.wav" and you are asking to playEffect:#"button.wav" it will play on simulator, but will not on the device. This effect takes place because filesystem on your desktop is case-insensative, and on iOS devices it is not.
I have the same problem and find here. But I fix it by myself.
If you reinstall ios for ipad. the default switch(upon the volume) is default as "mute volume" method. Maybe I change it to "rotation" method when it is mute. It lead to all cocos2d can't play sound any more. So I turn the method back and set mute off. And then SimpleAudioEngine works well. It is ios system's bug.
Make sure to check your audio file itself. A Mono 16 Bit, Uncompressed wave with a sample rate of 441000 should 'just work'. I recommend grabbing a sample .wav from an online Cocos2D example, like the Cowbell.wav and try to play that file.