Big sound lag on some Android.

0 favourites
From the Asset Store
105 sound effects for your monsters in your video game.
  • Samsung Galaxy A8

    website

    Samsung internet Browser (based on an older chromium version): No lag

    Chrome: Some lag

    Firefox: Doesn´t work properly at all, completely broken lmao. I´ve noticed this with some of my projects aswell, they really don´t like Firefox at all. :V

    apk

    Same as Chrome on website, some lag.

    So one could assume that this is maybe caused by some update to Chrome, that hasn´t hit the samsung internet browser yet. What you could try is to change the sprite when "in touch". I tried that and it seemed that the sprite reacts instantly, while the sound is played with a delay. But my delay isn´t as severe as on your side so I´m not 100% sure about it. You could also try older versions of Chromium and see if the issue is solved by that --> in this case Chrome probably effed up something in an update.

  • I noticed some lag on an S8 Phone but the Tablet performed better than S8 though, not sure how much is an acceptable delay for you guys for the lag so I made a video where you can hear it and judge by yourself, hope it helps.

    Test Done using APK installed on both devices

    Tablet Galaxy Tab A:

    Android version 8.1.0

    Video Link: https://www.dropbox.com/s/nvzjee5bdf51x6w/galaxy%20tab%20a.mov?dl=0

    =========================

    Galaxy S8:

    Android version 9

    Video Link: https://www.dropbox.com/s/v8msg885d3x7p1y/s8.mov?dl=0

  • NetOne Have you Web Worker enabled ('use worker' in the advanced properties setting)? If so, try with disabled worker.

  • Asmodean

    no not using worker as advised by Ashley

    tarek2

    Really appreciate you taking the time to do that.

    What you have demonstrated there is some serious lag. Especially on the S8.

    That is around 400ms.

    Not only will that make a playing a real-time instrument impossible.

    But if it is happening in Construct games that would also be unacceptable.

    It’s at this point I would love someone to tell me there is some issue in my events but I think we are exposing serious touch lag issues on android here. (at least with regard to sound and at least on Moto and Samsung devices)

    Slightly off track. Anyone with Apple I phone?, are you getting similar lag on website? (Wondering is this actually just a Android issue)

  • tareks lag was crazy, that makes a game unplayable..

    But as I responded in the beginning. We are hundreds (thousands?) of users creating and playing construct games on phones, so there is no "general lag" of 400-500ms for touching objects. you should never be able to play a precision or quick reaction game if you had 500ms lag!

    maybe try to add also one graphic change (like change the bg color) in the same event as changing frequency in your test project. if that will change instant, but the frequency change is delayed then there are no touch lag, it is just a "sound lag"..

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • fredriksthlm

    I am happy to update the experiment to include an animation of some sort and we can see how it compares,

    but my primary here interest is in touch to sound lag for real-time music instruments and right now the evidence points to a serious sound lag issue on android.

    There may be thousands of construct users but ive been here long enough to know that I am one of a very very small handful of users who regularly test and post bug reports as I really want construct to be the best it can be.

  • fredriksthlm

    I am happy to update the experiment to include an animation of some sort and we can see how it compares,

    but my primary here interest is in touch to sound lag for real-time music instruments and right now the evidence points to a serious sound lag issue on android.

    There may be thousands of construct users but ive been here long enough to know that I am one of a very very small handful of users who regularly test and post bug reports as I really want construct to be the best it can be.

    Yes... But it could be interesting to see if you experience the lag as a touch lag or a sound lag.. but do as you want.

  • No its a good test. I will try to update tonight. Wont be till much later tho.

    edit > WackyToaster already indicated that sprite animation reacted instant but the sound still lagged. But yea will test later. Need to go out and scare some kids first tho.

    🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃🎃

  • I made a test that might show the problem pretty well (make sure you only tap once). The measurements are usually not considered accurate though so take it with a grain of salt.

    wackytoaster.at/parachute/audioLag.c3p

    For explanation, this takes three timing measurements:

    Once the tap is registered, once the audio starts playing and once the audio stops playing.

    And then shows timings based on:

    Duration between registering tap and playing audio, duration from audio start to audio stop and discrepancy between the measured audio duration and the actual audio duration.

    On the Samsung Browser: No audio lag, low duration from tap to audio playing, discrepancy is in the low ms range, 10ms at most or even in the negative. I´d say an expected range.

    On Chrome: Audio lag, low duration from tap to audio playing, discrepancy is often arund 50-60ms.

    As it seems the tap is indeed registered asap, but the audio lags behind? However, 50ms isn´t all that much (3-4 frames) so considering how long the lag is... I dunno if it´s that or only that. Another thing is that the discrepancy sometimes even shows high negative values (-40ms) but there is still a very noticeable lag.

  • Android is just another way of saying audio lag :D

    I wish for the day when audio on android performs as good as on iOS where it is nearly instant.

  • Ok Halloween duty over back to s**t posting on the net..... hehe.

    anyhew....

    WackyToaster

    So your app is saying as far as construct goes it thinks the audio is playing and stopping within a few milliseconds which is good but not what is actually happening in the hardware?

    also

    2 more videos

    Samsung S7 Android 8 = lag

    drive.google.com/open

    Hawaei P10 Android 8 = lag

    drive.google.com/open

    all of these devices are lagging between 300-400 ms (I have checked in video editor)

    its a bit late and im knackered so I wont update the app to include animation right now but will do on the weekend

    however I think there is enough evidence here to clearly show that there is a major lag issue.

    edit > Tom I think there is far too much space between new lines (paragraph breaks) on desktop

  • Have just quickly raised a bug report.

    github.com/Scirra/Construct-3-bugs/issues/3455

    But will continue investigation here on weekend

  • From all of this it seems like like sound lag yes. No touch lag.

    Seems to be most noticeable in Oreo mainly?

    I have seen that there is a bug in 8.0 for low latency sound, which should be fixed in 8.1. Maybe you can verify if the devices you have problem with is running 8.0

    The issue is smaller in nougat and should be gone in pie

  • so far pretty much exact same lag showing in 7 , 8 , 8.1 and 9 on devices tested.

    Currently showing lag on 9 on S8 (as shown in tarek2s demo above and linked on the bug report)

    so unless someone can show otherwise Im going with the current evidence.

  • The Android ecosystem has had long standing issues with audio latency. Unfortunately this is in the Android platform itself, so is not part of Construct or the browser. This means there probably isn't anything we can do about it.

    For example I found this writeup about latency here: https://superpowered.com/androidaudiopathlatency

    Some choice quotes:

    The overwhelming majority of Android devices suffer from too high audio latency...

    Most Android apps have more than 100 ms of audio output latency, and more than 200 ms of round-trip (audio input to audio output) latency...

    Games: sound effects, such as explosions or gun sounds lag behind by a few frames...

    From my own testing a Pixel 3 with Android 10 and Chrome 78 had no perceptible latency, but a Samsung Galaxy S8 with Android 9 and Chrome 78 did, similar to the videos. If the problem was with Construct or the browser, then both devices would be affected. However the Pixel 3 is not affected, demonstrating the problem is with the device or the Android OS itself, and as noted there have been long-standing issues here.

    Therefore I'm afraid I don't believe there is anything we can do about this. There are lots of other people who badly want the Android audio latency problem to be fixed too, particularly developers of music apps. Not all devices are affected, but I guess the only thing to do is to wait and see if Google comes up with a way to have low-latency audio playback for all devices in future.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)