# kodi doesn't play video files with ac3 audio on RPi



## uzsolt (Apr 9, 2018)

I created a bug report about it: PR 227241. I copy from report:

I've a Raspberry Pi B+. I'm using FreeBSD 11.1 on it.
The Kodi doesn't play some videos and it seems the "bad" videos are videos which contains ac3 audio (avi, mkv). The video starts but with blank (black) screen (can't see any video) and without any audio. Files with "MPEG-1 Layer 3" audio works well.

I installed Kodi on my laptop (x86_64) and check these video files: plays well.

Kodi is installed from FreeBSD repository.

What other informations do you need? Should I share some bad videos?


----------



## acheron (Apr 10, 2018)

Can you share the videos? (in private if you want)


----------



## uzsolt (Apr 13, 2018)

acheron said:


> Can you share the videos? (in private if you want)


Yes, of course. Sorry for late: http://uzsolt.hu/tmnt-tfd-xvid-sample.avi


----------



## acheron (Apr 16, 2018)

It works for me on a RPI2 with -CURRENT. I'll try to resurrect my rpi1b and see if it works on it.


----------



## SirDice (Apr 16, 2018)

https://kodi.wiki/view/Raspberry_Pi_FAQ#Video_and_audio_formats_the_Raspberry_Pi_can_playback

If I remember correctly, the Pi 1 can only do AC3 with passthrough (meaning your AVR or TV has to decode it), the CPU simply isn't powerful enough for the software decode it.


----------



## uzsolt (Apr 16, 2018)

acheron said:


> It works for me on a RPI2 with -CURRENT. I'll try to resurrect my rpi1b and see if it works on it.


Thanks for your check!



SirDice said:


> If I remember correctly, the Pi 1 can only do AC3 with passthrough (meaning your AVR or TV has to decode it), the CPU simply isn't powerful enough for the software decode it.


Oh, maybe it can be the problem. And this can be the reason why doesn't show any video on TV? My (our) TV is a simple, old (but well-functioning) CRT.
Do you have any idea how to solve this? (without to buy any newer RPi or TV  )


----------



## SirDice (Apr 16, 2018)

Remember, the Pi was developed/designed as a learning project, it was never intended to be used as a fully blown media player. In this respect there's much better hardware around. That said, my Raspberry Pis all work fine (LibreElec), but most of the heavy lifting (audio decoding) is done by my AVR.


----------



## acheron (Apr 17, 2018)

It also works on my rpi1b (still running -CURRENT). I had to set gpu_mem=128M in /boot/msdos/config.txt (as mentionned in pkg-message)


----------



## uzsolt (Apr 17, 2018)

acheron said:


> I had to set gpu_mem=128M in /boot/msdos/config.txt (as mentionned in pkg-message)


I did it too as I've installed kodi (some months ago).


----------



## uzsolt (Apr 30, 2018)

Hm, I think I found the solution. I've turn off the "Audio Passthrough" and set the audio output to "2.0". Works fine.


----------



## BSDAppentic3 (Apr 30, 2018)

Which Desktop Environment or Window Manager are you using? Because depending of which you use, the usual it's that they come with their own music players.


----------



## uzsolt (May 1, 2018)

BSDAppentic3 said:


> Which Desktop Environment or Window Manager are you using? Because depending of which you use, the usual it's that they come with their own music players.


Without any WM/DE.


----------



## BSDAppentic3 (May 1, 2018)

uzsolt said:


> Without any WM/DE.


Such fear.
Then how do you "visualize" your programs? Gnome, KDE, Xfce, I3...none of them?
I can't believe it.


----------



## uzsolt (May 1, 2018)

You should believe it. Why do I need any WM on RPi? I don't run any programs with GUI only the Kodi. The multimedia/kodi contains /usr/local/bin/kodi-standalone which runs the X server.

You can run `startx` with empty xinitrc and you'll get a graphical interface - without any WM.


----------



## Phishfry (May 1, 2018)

Have you never heard of GeeXbox before it was Openelec?


BSDAppentic3 said:


> I can't believe it.


They build entire media center distros built around Kodi and tvheadend


----------



## BSDAppentic3 (May 1, 2018)

uzsolt said:


> You should believe it. Why do I need any WM on RPi? I don't run any programs with GUI only the Kodi. The multimedia/kodi contains /usr/local/bin/kodi-standalone which runs the X server.
> 
> You can run `startx` with empty xinitrc and you'll get a graphical interface - without any WM.



Aja 
Sorry, I can't remember it.
You mean that you only installed Xorg and run startx?


----------



## uzsolt (May 2, 2018)

No, only run `/usr/local/bin/kodi-standalone`.


----------



## BSDAppentic3 (May 2, 2018)

uzsolt said:


> No, only run `/usr/local/bin/kodi-standalone`.


So you run from CLI?


----------



## acheron (May 2, 2018)

Yes, Kodi is an EGL application on the rpi, you can run it directly from the console


----------



## uzsolt (May 2, 2018)

BSDAppentic3 said:


> So you run from CLI?


Almost. I run it via `inetd` on demand (if an Android app starts, try access kodi's port, so `inetd` will start it - here is a howto (on hungarian)).


----------

