Playing Audio from a specified verse -- inconsistency

In some Scripture projects I’m helping with, it is possible to launch the app, pick a book, chapter and verse, and then play the audio from that position. SAB opens the book at the correct chapter and verse, and hitting the play button launches the highlighted audio playback from that point.
On other Scripture projects, hitting play after choosing the book, chapter and verse has a different result. The verse is very briefly highlighted (i.e. a flash of color) and then the chapter scrolls back up to the top and the first verse or section header is highlighted and read–and the audio continues from that point.
I haven’t been able to tell what is different in the projects to cause the different behavior.
I’m using the latest version of SAB (7.2) with each. I did notice that the projects with the problem both use 3gp files, but I don’t have enough variety in my projects to test if that’s the problem. Is it a problem with VBR files? I don’t know if the source files for the 3gp audio were VBR. SAB 7.2 flags when mp3 files are VBR, but I’m not sure if it does the same with 3gp. Any ideas?

3GP mainly uses AMR (Adaptive Multi-Rate Codec) to my understanding it is a variable bit rate. But it is in a different container to MP3, since the 3GP is actually a video container. Some video containers are better at random access than others.

Your observation seems to imply that CBR MP3 will be more reliable for random access than 3GP.

@Andrew_Shafe and @mcquayi, I’ve noticed the same problem in apps that I’ve created with SAB 7.2 and I’m using MP3 with fixed bit rate. You select John 3:16 and it jump to the correct location, but when you click Play on the audio it will start with the beginning of chapter 3 of John.

I have the additional problem that my app is also not highlighting text in sync with the audio even though I created timing files and I have the box checked that says “Highlight the current phrase when playing audio”
Do either of you have an idea what I might be doing wrong?

I just went back and the previous version of the same app (that was compiled with SAB 7.0) did not have this highlight problem.
I’ve got a draft of my app up on Google Play if you want to check it out: https://play.google.com/store/apps/details?id=net.tembiya.ntgen.kdh

Hi Andy,
I downloaded and ran the app. It looks like it only includes audio for Genesis, is that right? There is no audio for John. Either way, there’s no highlighting at all, correct? What do you see if you run “Fine tune timings” from within SAB? Is the highlighting displaying correctly there? I’m assuming you’ve run Aeneas and checked that the timing files it produced are indeed the ones that SAB is listing. They should appear under the Audio menu, Audio Files tab. Does it show the size of the mp3s as well?

Ian, the highlighting is synched correctly with the 3gp files (though you have to do the synch with the mp3 and then switch out to the 3gp) so it doesn’t seem to be CBR / VBR problem. It seems more to be an issue with SAB that it’s not playing the audio from the selected verse position. Or rather, more likely my missing something since some apps play the audio correctly, and some jump back to the start of the chapter. This problem is a show-stopper for two apps I’m working on, so I’d love to find a solution soon.

Well, I was sent the original mp3s and substituted one for a 3gp chapter file, then rebuilt the app. That chapter works! I can go to a specific verse and play the audio from there, while the other chapters still don’t work. So it looks like that’s a piece of useful information, but that still doesn’t explain why it doesn’t work in Andy’s project.

I just tried another app with mp3s, and it doesn’t work in that one! So now I’m puzzled…

Hi Andrew,
I think I found a solution, just removing the timing files then adding them again - more details below.

For starters, yes I had added the MP3 files, showing the size of the MP3, I ran Aeneas and used fine tune timing for each of the chapters, replacing the old timing file with the corrected one.
Thanks for your detailed questions, I’ll answer them so that anyone else with this issue might find the solution too.

  1. Yes, my Gen+NT app only includes audio for Gen 1-15 and Luk 6-12.
  2. My example about John 3:16 is from a different app I have - but it worked the same way about playing from the beginning of a chapter rather than from a specific verse.
  3. In the app version 2.1.2 (what’s on Google Play right now) the highlighting didn’t work at all in Genesis, but did work in Luke. You can tell me if that’s the case for your app as well (checking Genesis 6 vs Luke 6)
  4. I opened up SAB and attempted to Fine Tune Timings for a chapter that wasn’t highlighting (in Genesis). To my surprise, the fine tune timings HTML opened up but there was no scripture text showing at all and no timing numbers … strange. When I selected fine tune timings for a chapter of Luke the Fine Tune timings HTML window opened up correctly and highlights correctly. When I canceled edit of a Genesis timing file and returned to SAB I noticed that now SAB didn’t show a timing file for that chapter - this did not happen for Luke.

Solution:
I figured something must have been a problem linking the MP3 files and the timing files. I simply removed the timing files from the SAB project then added the timing files back again. Now within SAB the Fine Tune Timings works just fine for each of the chapters with Audio in Genesis and Luke.

I had actually previously created the timing files within a separate app that is Genesis only, and since I was using exactly the same MP3 files in the Gen+NT app I had simply copied the MP3 and timing files to the new App. Anyways, after removing the timing files and adding them again I made a new version of the app version 2.1.3 and after testing I see that highlighting works correctly. Interestingly I can’t get the highlighting problem to repeat: If I select Genesis 7:7 or Luke 7:7 then turn on audio it it correctly plays the audio starting at that verse - not from the beginning of the chapter like it had done previously.
I’ve already submitted version 2.1.3 to Google Play, so it might not be too long before they remove 2.1.2 and replace it with 2.1.3 (I wish the updates were immediate, but apparently have to be approved again?)

Concerning your discussion with Ian @mcquayi I initially thought that it jumps back to the start of the chapter when the audio player is not already up. You might want to try making an app where the audio toolbar is always on, and see if that makes a difference. When it seemed inconsistent to me that seemed to make a difference. But now with the new build of my app the audio is always playing from the correct verse - just not sure what is different now. You may want to just remove the audio and timing files then add them both back again and see if that works too.

Hi Andy,
I had changed chapter 1 to be an mp3 file (not .3gp like the rest) and it still didn’t play the verse from the selected point–just scrolled back to verse 1. Then I deleted all the audio and timings, and added them back again, as you suggested. I didn’t re-run Aeneas–just loaded in all the old files. Built the app and chapter 1 now works correctly! It plays from the selected verse. All the other chapters, which use 3gp, still do not work. So there seems to be a “refresh” issue with linking the timings and playing them correctly as you suggested. And currently it looks like using 3gp files prevents the audio from playing at a specific verse location.
Has anyone else built an APK with 3gp audio and tested this?

Update: I changed Chapter 2’s audio to an mp3 and rebuilt the app. It didn’t work. I tested chapter 1 again, just to make sure it worked, and it didn’t work either! Neither would play the audio from the selected verse. I went back to SAB, deleted chapters 1 and 2, then re-added them again as mp3s with their timing files and rebuilt. They both work! And the 3gp chapters still don’t.

1 Like

I agree that it must be something like a refresh issue, have you attempted to simply delete the .3gp files and add them back again. If that works then it might not be a problem at all with .3gp vs .mp3
It would be helpful to know if the developers are looking into this issue.

Deleting and re-adding the 3gp files does not work, so it looks like this is definitely a problem with that file format. For now I’ve switched back to mp3s (though I have to “refresh” SAB as we noted above) and it seems to work. I’ve posted a bug on this issue.

@Andrew_Shafe,

You should know that 3gp support in the App Builder is not good. If you add a 3gp file, SAB can’t figure out the duration of the audio. You have to add the mp3 version and then edit (double-click on the entry in the audio list), to change the path from mp3 to the 3gp and I believe the duration stays in SAB.

I would prefer that we deprecate the use of 3gp. Our intern did research on supporting ogg opus files instead of 3gp for better quality smaller files. The limitation is that ogg opus is only supported on Android 5.0+. Thoughts?

Thanks,
Chris

Hi Chris,
Thanks for the very interesting tidbit! I’ll try that.
3gp has been a useful option for our teams, trying to squeeze in as much audio into the APK as possible within the Play Store limitations. It fits the ministry model better, since folk can download just one file (easy) and the whole audio in one sitting (useful if they have to go to some specific location to get internet, but don’t have the capacity to download or stream on demand at a later time). Anyway, it would be great to have another option.