Skip to content
This repository has been archived by the owner on Apr 23, 2023. It is now read-only.

Unable to play opus files in Windows 10 and Android 10. #168

Open
gandalf15 opened this issue Jul 19, 2021 · 3 comments
Open

Unable to play opus files in Windows 10 and Android 10. #168

gandalf15 opened this issue Jul 19, 2021 · 3 comments

Comments

@gandalf15
Copy link

Hello,
First of all thanks a lot for this amazing work.
I would like to ask for a help. I am able to convert my books from aax to opus files with this command bash AAXtoMP3 -o -A myAuthCode -t /home/marcel/Books/ ./audible_dir/Content/*

The problem is that I am unable to play them On Android 10 phone (tried different makes) with any player except VLC. However, VLC has problems to fast forward and rewind back. Any other apps like Booksonic or Smart AudioBook Player that I have purchased are unable to play the files and just pass through the files with the result that the book is finished.

In addition, I tested the files with these players:

  • VLC (Windows 10, problem with fast forward and rewind)
  • Totem (Pop OS 20.04, No problems at all)
  • Groove Music (Windows 10 default player, , problem with fast forward and rewind)

Opus file specs:

  • Container: Ogg
  • Codec: Opus
  • Channels: Stereo
  • Sample rate: 48000 Hz

An interesting thing is that if I use SoundConverter in Pop OS or LameXP in Windows 10 and set it to the same output parameters as the file has currently, the resulting output opus file works without any problem.

Here is one opus file that was converted with AAXtoMP3: https://drive.google.com/file/d/19tjDo2xWuycRUbdWOEsJ43f9QKOD2GzY/view?usp=sharing

Any help is very appreciated.

@rmlrml
Copy link

rmlrml commented Sep 16, 2021

I also converted a book to opus files and am having similar issues.

Audacious player plays the files with no problem, but Deadbeef player will only play the first file, and returns vague "ERROR: could not load:" on all the rest.

I noticed that the README.md states "The extension is .ogg", but in fact the files that my copy of AAXtoMP3 (v1.3) output had ".opus" extensions. I tested by changing one file's extension to "ogg" but it didn't enable deadbeef to play it.

I was also curious if the metadata could be causing problems. I removed the VorbisComment tag from the file - no go. Wasn't sure if there could still be other issues with the opus headers.

I also tried "converting" the file to same parameters as you did (using soundKonverter) and it worked for me too.

One additional bit: I opened one of the suspect files in MediaInfo and it reports that it has video content!

General
Complete name                            : /home/ryan/Books/Bakunin-God-State/opus/God and the State (Carl Manchester)/God and the State-2 Chapter 2-testing.opus
Format                                   : Ogg
File size                                : 1.94 MiB
Duration                                 : 2 min 6 s
Overall bit rate                         : 128 kb/s
Movie name                               : Album cover
Description                              : Cover (Front)
Writing application                      : Lavc58.134.100 libtheora

Video
ID                                       : 828721532 (0x3165497C)
Format                                   : Theora
Duration                                 : 2 min 6 s
Nominal bit rate                         : 200 kb/s
Width                                    : 1 214 pixels
Height                                   : 1 214 pixels
Display aspect ratio                     : 1.000
Frame rate                               : 25.000 FPS
Compression mode                         : Lossy
Bits/(Pixel*Frame)                       : 0.005
Writing library                          : Lavf58.76.100
Track/Position                           : 2

Audio
ID                                       : 3836409110 (0xE4AAF516)
Format                                   : Opus
Duration                                 : 2 min 6 s
Channel(s)                               : 2 channels
Channel layout                           : L R
Sampling rate                            : 48.0 kHz
Compression mode                         : Lossy
Writing library                          : Lavf58.76.100

The file that I converted with SoundKonverter only has audio content.

Something's going wrong in the conversion to opus.

@patrickhoette
Copy link

I saw some mention online that FFMPEG might not be able to add cover art to Opus files which would explain the video data. Seeing as ogg does offer support for video it might very well be that this is what is causing audio players to error. I encountered the same issue when having chaptered Opus files in both the "Voice" Android app and the PlexAmp Android app both running on Android 11. Seeing as there appears not to be a condition in the script which turns off the image input in the script when it is splitting the main file into chapters this could be causing the issue. Hope this helps to fix the issue as I would really love to use Opus to encode my audiobooks.

@patrickhoette
Copy link

Removing lines 872, 873, 875 & 876 fixed it for me. So presumably changing these to be conditional on not having the opus format selected will fix the issue. Its important the -map options are also removed or FFMPEG will give an error. I'm not amazing with bash nor super familiar with the script so I will leave the actual implementation of the fix up to someone else. I literally just deleted the lines in my own copy of the script as I will only use the opus format anyways.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants