TS file skipping

An audio delay can also be a negative value.
At least my AVR is providing both options (auto delay / manual audio delay) with positive and negative values.
I never had a problem with the auto setting, so I don’t need to adjust it for every possible input.

I didn’t see, that you are using the Leia version of LE.
You are right, that this can’t be a Kodi problem then.
I will talk about it in the team and I’m sure we can provide a fix for it soon.

1 Like

I think @afl1 said lateframes patch was causing the stutter with audio offset set, should be fixed in tomorrow’s nightly.

1 Like

The fix in the nightly from 2019-01-04 works - thank you very much :smile:

Regards

Arne

1 Like

Good to hear, thanks

1 Like

I have similiar observation (dunno if .ts only, spotted also on mp4 and internet video streams). Unfortunatelly I need audio 175ms earlier (for TV through offline AVR). I have 175ms without problem on previous 7.0.3 :frowning: Playing with it two days, symptom [100159.266293@2] vidioc_qbuf skip: index:190708:190707. I dont tested LE 9 Beta yet…

I have 8.95.7 from 3.1, will try nightly then. :slight_smile: (side question, for manual copy files to the /flash, could I use CoreELEC-S905.arm-9.0-nightly_20190109.tar, or I need extract fat partition from CoreELEC-S905.arm-8.95.7-Odroid_C2.img.gz?)

EDIT: Testing 20190109, I noticed that audio has slight delay in menu (kodi sounds). So far the playback looks much better, I didnt notice skipped frames yet (two configurations). Delayed Kodi sounds would be nice to have also fixed, but if I would choose between video issues, and sounds in menu… I would disable kodi sounds :slight_smile: (not sure if menu sound delay is caused by the same fix for the skip frames@video)

Are you saying, the audio is behind the display?
E.g. you switch a menu entry, see it on the TV and a bit later you hear the sound?
That’s strange. In most cases it is the opposite because of the video processing in most modern TVs.

Did you enable any special audio processing options in your AVR?
Does your AVR provide the above mentioned auto delay/auto lip sync option?

Yes, audio is little bit delayed (Kodi menu). This happened the same way after update 8.59.7 to nightly on both configurations:

C2 - HDMI - Phillips TV. Adjust refresh rate disabled, Video sync to display ON, 50Hz

C2- HDMI - AVR (offline passthrough) – Panasonic TV. Adjust disp. to refresh rate ON, Video sync OFF.

AVR seems to provide auto/delay, although I didnt turn AVR ON yet (with updated nightly). I am using Audio offset only for C2-TV and C2-AVR(offline)-TV. When AVR is ON, I am not using audio offset and with 8.95.7 was lip sync allright (with AVR auto sync enabled).

But! the nightly doesnt seems to cause lip/sync delay. Just Kodi sounds delay, when moving menu. When I play video, sync is fine on the same value offset -175ms, which was setuped also for 8.95.7, and was/is spot on (but with video frame skips).

8.95.7 - Kodi menu sounds OK, lipsync ok at -175ms, video skips
nightly - Kodi menu sounds little bit late, lipsync ok at -175ms, no video skips so far (short period of testing but very promising)

P.S.: the offset value +/-; Kodi just saying earlier, but you set “earlier” by pressing right on audio offset scale… So its kinda relative, to be perferctly clear. Anyway, I dont think polarity matters.

At least it sounds like your audio delay is consistent across GUI and movies in the latest nightly, now.
During movie playback you are adjusting it to -175ms to let it be in sync with the video.
The GUI does not provide such an option and the video is delayed.

The real question is: Why is the sound delayed at all in your setup?
Can someone with a C2 confirm this behavior?

Well, I have quite long history with OE/LE +Rpis, and I dont remember I ever had Menu sounds delay (maybe there was but not noticeable, only few ms?). But for videos, in 80% cases I must setup at least 80ms for direct TV (and a bit more for AVR, depends on TV/AVR), its a known thing and it corresponds as you wrote with video signal processing.

Maybe the render system changed, but I can tell I didnt notice kodi sound delay in CoreELECs before, but I noticed it immediatelly after update to nightly. Cant estimate ms, but it could be 175ms.

Panasonic https://streamable.com/u8ham
Phillips https://streamable.com/9caer

Would be good if someone could confirm this, maybe it is combination of some of latest change? But again, if is this needed to have video without frame skipping even with audio offset, then I can live with that…

Forgot to mention, didnt using hdmi passthrough i tests I describe, as TV’s cant decode all codecs/number of speakers, I am using audio passthrough only when using AVR

Allright, I did rest of tests today @nightly, with AVR and audio passthrough. Seems, that “Auto Delay” function on AVR doesnt work anymore. But I can setup audio offset manually of course (-125ms for the AVR + projector).
Menu sound delay is present. Frame skipping seems to be solved -no matter if AVR on the way or audio passthrough enabled/disabled - with that release.

Will do more testing with AVR used in HDMI path today.

Logically, it doesnt make sense to me, but I can confirm, that Menu kodi sounds delay is gone, when I turn audiooutput.streamsilence (“Keep audio device alive”) from original 1 (minute) to 0 (disabled).

Will test if that returns back AVR auto lipsync also later.

That’s really strange and I’ve never heard about this issue before.
But I have to admit, that I generally disable these annoying GUI sounds.

Me neither, never before CoreELEC-S905.arm-9.0-nightly_20190109 with audiooutput.streamsilence 1 (which is I believe default option and I assume it was there since beginning, when I started use CoreELEC.

Anyway, first AVR tests concludes, that AVR auto delay for lipsync doesnt work with that version/settings, audio offset must be setuped.

The default setting for audiooutput.streamsilence was changed to 0 (disabled) in our builds not so long ago, if you have an old install though then this wouldn’t have updated for you.

not so old… I am updating through manually copying new /flash partition… dunno, on what CoreELEC version I started, but last two previous versions was 8.95.7 release, and the nightly 2090109 (using now).

@anon88919003, did you have any informations about this relation? I mean streamsilence / audio delays / skipping frames? This is mystery for me, and I would like understand what happening there.

I also see, that Audio should be changed (according github) from Optimised to Best Match. Any background to that one? I used Optimised for years…

Why would you update that way? The idea of updating by dropping the tar into the update folder is to have everything that needs to be updated - updated.

@JimmyS if you are updating then the setting will not change just because we update the default, only on a new install would you see it change.

I have no information but osmc also uses the same default and I can only assume for the same reasons.

We already use best match as default for audio config as well.

@Offtopic

well, because I didnt trust much “automatic” actions on Rpi/C2 box itself during boot. I know, that in history .tar method was kinda trustworthy after all, but I did it rather manually, when box is online, I can see progress (ie. if something faults or not)… And safelly reboot when all is done and checked. Using it years and 0 problems :slight_smile: I dont think I actually doin something different than .tar method does…

The introduction of .gz was “bad news” for me, as I always take care about partitions by myself… And I was right to avoid that, there was problem with partition script from the start… Plus, I used different partitions on different media, so that script of course is not usable for me :slight_smile: I know its propably solved already but still, better be safe than sorry…

@anon88919003
Thanks, I could try dig around osmc if I found something more…
Because if audiooutput / Optimized mode / any other Kodi func is broken (or breaks other function, for what reason?), I would like to know that, to be aware and stay away from those options. Only “silent” changing defaults on clean installs, or denying Kodi options isnt good way IMHO, because Kodi users from other platforms could be confused, when “their choice” is missing or acts differently, plus those users whose installed CoreELEC before, with other default settings (like me, apparently?). Maybe some errata / wiki page called “Kodi differences on Amlogic platform” and description issues / platform specifics wrap-ups there would be really good…

I remember, that long time ago, on Rpi1, Optimalized option solves some other “light” issue I had… Dont remember which (maybe something with frequency or passthrough), just example why its important to know, when something didnt worked as expected (and best way know a little why its broken, so I could assume, if that option will be fixed in future, or… :slight_smile: )

I see the changes here are left and right, and wondering if its because changes in Kodi beta cycles, or something else, related to the Amlogic platform. With that many changes latelly, I just waiting for final Kodi, before I will do another proper testing (settings - delay - frame skipping, AVR On/Off).

https://kodi.wiki/view/Audio_quickstart_guide
This is recommended settings from kodi

1 Like

Thank you! Weird, that Kodi default value is optimized in contrary…

Btw., I tested latest Kodi for Windows, and there is no “kodi menu sound delay” when using audiooutput.streamsilence. :thinking: