- This topic has 5 replies, 3 voices, and was last updated 10 years, 8 months ago by Uplink1001.
-
AuthorPosts
-
Uplink1001MemberHi.
Just on with a educational app and need a little help with the audio.
Problem is ( there are quite a few screens with audio that is called from a button, all seems fine until the app has been running for a while, or when the buttons pressed reach around 25-30 then there is a terrible lag in the audio starting, (sometimes not playing at all),i have tried using the audio widget as suggested in other parts of the forum, but this seems to be worse?,
what i have been doing is placing the following in the Actions: RunJavascript
if (media2){media2.stop();}
done = function() {};
error = function() {};
status = function(status) {};media1 = phoneui.createMedia(‘E.mp3’, done, error, status);
// then just use Cordova Media API:
media1.play();
media.release();can anyone give me help with this, have i got the code right? or is there anything else i should add. using the above did speed up the audio playing when the button was pressed, but as said it stills lags after 25-30 presses of the buttons.
is there a way to media.release when the pages are changed?
Just want to get this finished…….
Uplink1001
support-octavioMemberHi Uplink1001,
Your problem sounds very similar to this one: http://www.genuitec.com/support-genuitec/viewtopic.php?f=8&t=7153&p=25717#p25717
Is your problem like that? When playing an audio #25-30, or does it happen with a same audio widget trying to play it more than 25 times?
Note that the problem I mentioned is in the queue and development will be investigating next week.
Uplink1001MemberHi
The problem seems very similar to that topic,,
It only happens if I play more that 25 to 30 of the sound, then there is serious lag.
As I asked I think this may be down to media release. Does this work as it should?
I may be wrong but is it down to a build up of audio files not being cleared?,Uplink1001
Uplink1001MemberJust an idea,
could it be down to mobione not putting the audio files into a media directory? When I do a build all the audio files are put in the parent dir?
Would this make any difference?.
Uplink1001
support-michaelKeymasterUplink1001,
We will have to dig in very deep to get our heads around what is dorking up. There are 2 related issues: the start/stop latency you are observing and the fail-to-play for 28+ controls. We can replicate both issues in a common test case. We have this issue in this week’s dev queue for investigation. Will updated you when we learn more.
Uplink1001MemberHI.
Thanks for the quick reply.
Hope you can get this sorted, as the basics of the app is finished apart from the audio.Thanks again
Uplink1001 -
AuthorPosts