[AUDIO PLUGIN / CONSTRUCT BUG] playing audio twice

Bugs will be moved here once resolved.

Post » Fri Apr 24, 2015 10:22 pm

Problem Description
when using audio plugin on all platform (ejecta,cocoonjs, phonegab etc...)
when set action to play audio it play it twice (double)

Attach a Capx
NEW PROJECT > ADD AUDIO PLUGIN
on start of layout > play audio "tap.ogg" or "tap.m4a" (tap.ogg for example)

Steps to Reproduce Bug
    NEW PROJECT > ADD AUDIO PLUGIN
    on start of layout > play audio "example.ogg"

Observed Result
Image

Operating System and Service Pack
WINDOWS 7 SP1 - OSX YOSEMITE 10.10 VMWARE

Construct 2 Version ID
203

the prouf
if we create new project without any actions and or audio plugin
and export to ios (ejecta, cocconjs, phonegab etc ...) and add the following javascript call into index.js to play audio (just for test)

var audio = new Audio('media/tap.m4a');
audio.play();

it plays one time whereas it plays twice with audio plugin
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Fri Apr 24, 2015 11:39 pm

if we use

on start of layout > execute javascript "var audio = new Audio('tap.m4a');"
execute javascript "audio.play();"

it plays one time

then iam sure that is audio plugin problem
and it play all the sound twice at the same time
Last edited by matrixreal on Sat Apr 25, 2015 4:31 am, edited 1 time in total.
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Sat Apr 25, 2015 4:30 am

i just replace all my play sound "" with javascript call and i see some good performance on simulator and real device
cpu usage drop from 45 to 37%
memory use from 37mb to 12mb
i suggest to ashley to improve and revise the audio plugin because the double playing / loading sound affect some performance
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Sun Apr 26, 2015 11:19 am

Closing as Ejecta is no longer officially supported. We recommend using Cordova instead.
Scirra Founder
B
387
S
229
G
87
Posts: 24,245
Reputation: 192,060

Post » Sun Apr 26, 2015 12:50 pm

Ashley wrote:Closing as Ejecta is no longer officially supported. We recommend using Cordova instead.


yes its ok
but can you revise the audio plugin
it seem that the double playing / loading bug is from the audio plugin
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Tue Apr 28, 2015 12:14 pm

Ashley wrote:Closing as Ejecta is no longer officially supported. We recommend using Cordova instead.

please @ashley can you take a look on audio plugin for next update , it seem that it play audio alway twice
and the problem is not ejecta or others exporters but is on audio plugin
thanks a lot
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Tue Apr 28, 2015 1:07 pm

@matrixreal - your original report does not follow the guidelines so there is nothing I can do anyway, and I don't see that you've identified anything that has actually been broken by this, so it sounds like it's really working fine.
Scirra Founder
B
387
S
229
G
87
Posts: 24,245
Reputation: 192,060

Post » Tue Apr 28, 2015 2:22 pm

Ashley wrote:@matrixreal - your original report does not follow the guidelines so there is nothing I can do anyway, and I don't see that you've identified anything that has actually been broken by this, so it sounds like it's really working fine.

yes its ok its clear that it work fine but in same time its clear that it plays always double (twice)
what are the details/guidelines that i have to provide to prouve this bug ?
thanks
B
44
S
16
G
8
Posts: 791
Reputation: 8,279

Post » Tue Apr 28, 2015 2:31 pm

Can you actually hear it twice, or is it just making two requests in the network panel? The second request will either be deduplicated by the browser network stack or simply return from the cache, so it is probably totally harmless. I'm not at all clear that this actually has any disadvantage.
Scirra Founder
B
387
S
229
G
87
Posts: 24,245
Reputation: 192,060

Post » Tue Apr 28, 2015 4:40 pm

@ashley

i understand what you say and probably maybe it tike too time to revise the plugin
but what i have to say is :

1-some times i hear it twice (even when i just play the sound 1 times on start of layout like my example")
2-when i just excute a javascript call to play audio it play it one time (on device and on debugger for iphone simulator)
3- i will try to mesure performance because i see some differences and post the screenshoots here

anyway thanks
B
44
S
16
G
8
Posts: 791
Reputation: 8,279


Return to Closed bugs

Who is online

Users browsing this forum: leena222 and 1 guest