mediathekview / zapp

German public broadcasting live streams as an Android app
https://mediathekview.de/news/zapp/
MIT License
199 stars 33 forks source link

Since version 8.0.0 the videos from the Mediathek section stutter #350

Closed Monstanner closed 1 year ago

Monstanner commented 1 year ago

Which channel does not work correctly?

As described above, the videos stutter in the Mediathek section. The livestreams are running so far without stuttering. I have tested all newer versions (8.0.0, 8.1.0, 8.2.0), but the problem persists.

My hardware and software: Device: Nokia 6.1 OS: Android 10 Vanilla

What is the problem?

cemrich commented 1 year ago

Thank you very much for your feedback!

This is most likely a problem with the updated version of exoplayer and your device. Do you have similar issues with other video apps? Does it help to download the show? Are all videos stuttering?

Monstanner commented 1 year ago

Thank you very much for your feedback!

This is most likely a problem with the updated version of exoplayer and your device. Do you have similar issues with other video apps? Does it help to download the show? Are all videos stuttering?

So when I'm in the Mediathek section and watch the suggested videos, it's different. Sometimes the videos stutter only after 10-15 seconds, sometimes only after 40 seconds and sometimes right at the beginning and that's the whole video. When I then look for films, as an example here now the film "Jeanny - Das fünfte Mädchen", then it stutters permanently. If I download the videos / movies in the highest quality, then it stutters too. With downloads of Low and Medium, everything seems normal. I have only noticed such behavior with Zapp. Other apps that play/stream videos (VLC, NewPipe, etc.) have no problem. Not even with videos in high quality (1920x1080). Except for the app Xtra. It's also the case that when I watch streams in the best quality, it stutters too. That's why I set the quality to 720p.

cemrich commented 1 year ago

Thanks for the clarification!

Xtra is using the same version of Exoplayer, so I suspect an issue on their side. The is a similar issue open at Xtra: https://github.com/crackededed/Xtra/issues/197 Can you confirm this bug on your device? Also, there is a solution posted as response to this issue. Does it fix the issue for you?

Monstanner commented 1 year ago

Thanks for the clarification!

Xtra is using the same version of Exoplayer, so I suspect an issue on their side. The is a similar issue open at Xtra: crackededed/Xtra#197 Can you confirm this bug on your device? Also, there is a solution posted as response to this issue. Does it fix the issue for you?

Yes, stuttering is no longer present in Xtra due to this option.

OddSobriquet commented 1 year ago

The problem also applies to live streams, not just Mediathek.

https://user-images.githubusercontent.com/72888738/212301455-95a0d822-2778-48d0-a2e8-fc6504902ae7.mp4

Edit: in Xtra I could mitigate the problem by choosing 480p video resolution. On such a small screen as a phone the difference between SD and hd is hardly noticeable anyways. (Same applies to Newpipe|Sponsorblock)

Monstanner commented 1 year ago

The problem also applies to live streams, not just Mediathek. 31905.mp4

I checked it again and you're right. I had intended, through your comment, to make a list of the stations that stutter. But then I noticed at the mdr that only some programs stutter and some do not. So it can also have something to do with the quality of the image and how much happens in the image. It stuttered on a music show, but not on a talk show. Both programs had a good picture quality but the music show was much more going on in the picture. That's why I think the list is pointless, as it varies. I hope that the solution from Xtra can be adopted. As a workaround for the Mediathek, you share the video with an app like VLC.

OddSobriquet commented 1 year ago

So it can also have something to do with the quality of the image and how much happens in the image.

I can imagine it being connected to stream (live or locally stored) quality. I would've tried using a lower stream quality to see if the problem persists, but unfortunately Zapp doesn't offer a setting to change stream quality / resolution / FPS (neither in settings nor in the player directly [little cog wheel as in Xtra, Newpipe]). I already ran out of data this month so...

I can attempt downloading a programme using low resolution option but that won't be happening until after the week end.

cemrich commented 1 year ago

Thank you very much for debugging this!

This seems to be an issue with exoplayer. They changed something in the mechanics of which decoder is selected between versions 2.18.1 and 2.18.2 which seems to cause some devices to choose a software decoder. See https://github.com/google/ExoPlayer/issues/10808 for a similar issue.

Xtra works around this issue by optionally forcing a hardware decoder in the settings. I would like to avoid this for Zapp. I will wait for the next Exoplayer update - than we will see, if this issue is fixed.

Spielmops commented 1 year ago

The problem seems to be the coding: often H265 is used for streams, regardless if live or Mediathek. Together with the resolution Full-HD it is something not every device is able to play fluently. For paid networks there is a switch for lower quality and if I use that (goto settings/wifi/my-wifi, set it to paid network), I can play the file without issue. The solution could be a switch for lower quality everywhere.

Spielmops

OddSobriquet commented 1 year ago

Confirms my suspicion. As mentioned: in Xtra switching to 480 the stutters and choppy playback disappeared.

I think a quality setting hidden behind the cog (where audio channel and playback speed are located) would be the "easiest" solution.

I wouldn't remove the quality preferences for metered/ unmetered connections from the main settings page completely but I would implement it as a preference (a default go to) which can be overridden at any time using cog>quality when watching a stream.

ChristianCiach commented 1 year ago

For what it's worth, I see the same issue on my new device "Lenovo m10 plus 3rd gen" that I bought for my mother. The devive is on Android 12 (all updates applied) and uses the MediaTek Helio G80 chipset.

On paper the G80 should be able to decode x265 in Hardware, so I guess/hope that this is a software issue. I cannot reproduce the issue with other apps like Joyn, but I didn't test Xtra.

The first few seconds of a stream are usually fine, but then it switches to HD and it immediately becomes choppy.

Are there any workarounds for the time being?

Edit: Downgrading to 7.0.4 (Github release) works fine, even though I already miss the zapping function :D Thanks for this awesome app, by the way! It is one of the very few apps even my stepdad can use.

ChristianCiach commented 1 year ago

Supposedly, updating exoplayer to 2.18.3 fixes the issue: https://github.com/crackededed/Xtra/issues/197#issuecomment-1440595715

As I can see, Zapp is still using 2.18.2, so an update may be worth a shot.

Monstanner commented 1 year ago

It looks like it's fixed with version 8.3.0 / 8.3.1. At least on my smartphone. Thanks for fixing. However, I don't close the issue because I don't know if there are still problems with other users' smartphones.

ChristianCiach commented 1 year ago

Can confirm that it is fixed for the MediaTek Helios based device of my mother. Thanks!

Der-Flip commented 1 year ago

Kinda forgot about this one, but yes Redmi9C with android 10 looks smooth as well

cemrich commented 1 year ago

Nice!

Thank you all for helping. Thanks to you, a lot of people are getting stutter free videos in a whole lot of apps :)