Kodi Community Forum
Testing audio engine ActiveAE - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Kodi Application (https://forum.kodi.tv/forumdisplay.php?fid=93)
+--- Thread: Testing audio engine ActiveAE (/showthread.php?tid=170338)



RE: Testing audio engine ActiveAE - eskape - 2013-10-05

(2013-10-04, 16:55)baijuxavior Wrote: I am using latest nightly in Windows 8 and there is a slight lip sync issue in all movies. Has anyone else seen this?

Yes, same issue when I use Minix X7 Mini with Android Monthly build Alpha 8.

I could provide you some logs if needed.


RE: Testing audio engine ActiveAE - FernetMenta - 2013-10-05

Post #1:

ONLY POST IN THIS THREAD IF YOU ARE WILLING TO BE A TESTER, CAN BUILD YOURSELF AND GIVE PROPER FEEDBACK (debug logs, etc)

WINDOWS and LINUX only.

Please refrain from just posting "I have a problem".


RE: Testing audio engine ActiveAE - baijuxavior - 2013-10-05

Debug log - http://xbmclogs.com/show.php?id=66169

I have to delay the audio by 0.175 to 0.225 seconds to get the lip sync correct. The issue is mainly in DTS movies.


RE: Testing audio engine ActiveAE - fritsch - 2013-10-05

Thanks for this feedback. Not long ago (approx 6 months with old SoftAE) we made a test with a lot of different hardware and came to the same numbers:

175 ms with 24.0 hz and 23.975 fps.

Therefore we ship that default offset with OpenELEC via advancedsettings.xml.

I think that is hw dependend and not introduced by software.

Code:
<advancedsettings>  
<video>
  <latency>
    <delay>0</delay>
    <refresh>
      <min>23</min>
      <max>24</max>
      <delay>175</delay> <!-- set to zero or adjust if audio seems out of sync with 24p movies -->
     </refresh>
  </latency>
</video>
</advancedsettings>



RE: Testing audio engine ActiveAE - FernetMenta - 2013-10-05

(2013-10-05, 15:26)baijuxavior Wrote: Debug log - http://xbmclogs.com/show.php?id=66169

I have to delay the audio by 0.175 to 0.225 seconds to get the lip sync correct. The issue is mainly in DTS movies.

Can you repeat your tests with
- passthrough disabled?
- without AVR


RE: Testing audio engine ActiveAE - stupid-boy - 2013-10-06

not big deal, but as i see it, let share. buffer allocated at AESinkALSA.cpp:347 is not freed.
if you don't disagree, i will report similar if i spot them.


RE: Testing audio engine ActiveAE - fritsch - 2013-10-06

You are right there. We shortly alloc it, in order to get a copy of the things succesfully initialized.

Mind sending a PR?


RE: Testing audio engine ActiveAE - stupid-boy - 2013-10-06

prefer to leave such 'founds' for you. you more regularly made PRs. also my machine is totally bloated now.


RE: Testing audio engine ActiveAE - fritsch - 2013-10-06

That stuff is handled in snd_pcm_close later, so freeing it before will end up in a segfault.


RE: Testing audio engine ActiveAE - franzem - 2013-10-07

Hi everyone,

I have got back from holidays and started testing the current build for Cue file support (git sha: aa5aa9971fcf5a22697f49ec6ab1892f7e054f3c). The transitions work perfectly now, so I have gone on to test some of the other albums in my library that use cue files.

Some albums play through perfectly, as expected. Other albums end after the second track without any kind of error and after handling the transition between the first two files perfectly.

I am sending an xbmc log file for such an album, plus a link to the mp3+cue in question. I import the files into the music library.

Log: http://xbmclogs.com/show.php?id=67050
Files: https://www.wetransfer.com/downloads/aa693501ba09288dfa45d7843a3dec3c20131007154830/97d3f43eb65d3712e60c888c896bc88720131007154830/feada5


RE: Testing audio engine ActiveAE - franzem - 2013-10-09

been looking into why some cue sheets play through and others end unexpectedly, and simply can't find a meaningful pattern. Here are two cue sheets, one works, one doesn't, and they look almost identical to me except for the play lengths of the songs. You can test these on any mp3, I was using the mp3 in my previous post.

Code:
PERFORMER "Various Artists"
TITLE "5 Years Desolat - Loco Dice - not ok"
FILE "hero1.mp3" MP3
  TRACK 01 AUDIO
    PERFORMER "Alexkid"
    TITLE "Enty"
    INDEX 01 00:00:00
  TRACK 02 AUDIO
    PERFORMER "Yaya"
    TITLE "Our Connection"
    INDEX 01 02:08:01
  TRACK 03 AUDIO
    PERFORMER "tINI"
    TITLE "Room 305"
    INDEX 01 05:46:01
  TRACK 04 AUDIO
    PERFORMER "Loco Dice"
    TITLE "Lolopopinho"
    INDEX 01 06:55:01

Code:
PERFORMER "Various Artists"
TITLE "5 Years Desolat - Loco Dice - ok"
FILE "hero1.mp3" MP3
  TRACK 01 AUDIO
    PERFORMER "Alexkid"
    TITLE "Enty"
    INDEX 01 00:00:00
  TRACK 02 AUDIO
    PERFORMER "Yaya"
    TITLE "Our Connection"
    INDEX 01 04:56:43
  TRACK 03 AUDIO
    PERFORMER "tINI"
    TITLE "Room 305"
    INDEX 01 10:56:35
  TRACK 04 AUDIO
    PERFORMER "Loco Dice"
    TITLE "Lolopopinho"
    INDEX 01 16:17:63

Also, here is a log file, first play ends after second track, second play plays all 4 tracks: http://xbmclogs.com/show.php?id=67579


RE: Testing audio engine ActiveAE - franzem - 2013-10-09

Update on cue file playback stopping:

I have spent a stupid amount of time experimenting on why certain cue files work and others don't. I have identified the frame parameter of the index as the problem area. The Index is of the form MM : SS : FF were FF is the frame of 1/75th of a second.

The frame in the "not ok" is always 01, in the ok one the frames are 43, 35, 64. So,

1) leaving the HH:MM the same as "not ok", but using 43, 35, 64 as the FF field works.
2) Using a larger number than 01 (say 60) doesn't work
3) Incrementing the fields by 1 doesn't work
4) Incrementing the fields by 2 works.

So, in the end I managed to get it working with the following INDEX parameters:
INDEX 01 02:08:10
INDEX 01 05:46:12
INDEX 01 06:55:14

Theoretically it should be any number between 0 and 75. Having cue files accurate to 1/75'th of a second is pretty meaningless actually. 1 second accuracy is enough! But having to edit cue files to make sure the index frame is 2 or more between tracks is completely counter-intuitive and a pain.


RE: Testing audio engine ActiveAE - FernetMenta - 2013-10-09

I have downloaded your sample and will have a look.


RE: Testing audio engine ActiveAE - FernetMenta - 2013-10-09

here is a fix: https://github.com/xbmc/xbmc/pull/3407


RE: Testing audio engine ActiveAE - franzem - 2013-10-10

I applied the patch and the fix works great Big Grin, I'll continue testing Cue files and let you know if I pick up anything else.

Loving the sound of the new AE btw.