1. No user installed addons are supported, python or otherwise.
2. No, they really are not supported.
3. They are not coming back
4. Read from 1. again

Any mention of illegal streaming sites, addons or any pirated material will not be tolerated. This is not democracy and any offenders will be banned and posts deleted immediately without warning.

Other than that, we hope you enjoy MrMC so far and we welcome any input and feedback you might have.

Team MrMC.

Stutter when using HW acceleration

FireTV Video playback support subforum
jamesp26
Posts: 63
Joined: 16 Apr 2016, 11:58

Re: Stutter when using HW acceleration

Post by jamesp26 »

Sorry to shamelessly bump this post. Is there any thoughts on whether future version of MrMC can go back to 2 threads for FFMpeg live tv? Although it had micro stutter it performed better than the current implementation which uses all cores and drops frames at high bit rates.

..or is MediaCodec deinterlacing the answer and i just need to learn to be a bit more patience :D .
User avatar
vlaves
Posts: 146
Joined: 04 Dec 2015, 10:33

Re: Stutter when using HW acceleration

Post by vlaves »

davilla wrote:Try with MediaCodec enabled. If should be able to handle h264 interlaced now.
So you want to tell here that MediaCodec is handling 1080i h264 interlaced TV? If yes, which deinterlacing method is used by MediaCodec?
User avatar
davilla
Team MrMC
Posts: 4377
Joined: 26 Oct 2015, 17:01

Re: Stutter when using HW acceleration

Post by davilla »

It is important to understand that there are two MediaCodec flavors, MediaCodec (Surface) and normal MediaCodec. I stick with MediaCodec (Surface) as it is the only flavor that can handle 4k media.

MediaCodec (Surface) does a firmware internal deinterlacing if used with h264 interlaced content. There is no selection or setting for it as there is no Android API to control it.

MediaCodec uses the normal, user set deinterlacing. To be honest, the advantages of MediaCodec (Surface) are so much more than the other flavor that we are thinking of removing MediaCodec (non-surface).

In my testing, MediaCodec (Surface) was handling h264 interlaced content just fine. I have to review with the file that jamesp26 submitted to check out why he is having problems.
User avatar
davilla
Team MrMC
Posts: 4377
Joined: 26 Oct 2015, 17:01

Re: Stutter when using HW acceleration

Post by davilla »

Ahh (light bulb goes off). The FireTV2 is a MediaTek 8173C - 2x Cortex A72, 2x Cortex A53.

The A72 cores are 64 bit.
The A53 cores are both 32 and 64 bit. So in terms of 32 bit (which is how we are built right now), there are really only two 32 cores. That explains the whole mystery of why forcing FFMpeg to two cores works much better than letting in pick backed on what android reports. Android is really reporting that there are four cores, mixing up the 64 bit ones when we want the number of 32 bit cores.
User avatar
vlaves
Posts: 146
Joined: 04 Dec 2015, 10:33

Re: Stutter when using HW acceleration

Post by vlaves »

davilla wrote:In my testing, MediaCodec (Surface) was handling h264 interlaced content just fine...
To be honest I turned off all Hardware acceleration as in some earlier versions of MrMC it was not used for Live TV (as far as I remember) and I had some trouble with playback of other files.
So will test now with MediaCodec (Surface) only turned on. Is MrMC in the meantime useing HW acceleration for Live TV too? I'm using a tvheadend backend and channels are H.264 1080i.

Btw. do you guys know which deinterlacing method the Fire TV 2 is using?

Thanks for your support and this great App :)
User avatar
koying
Team MrMC
Posts: 443
Joined: 20 Mar 2016, 17:49

Re: Stutter when using HW acceleration

Post by koying »

There is a design flaw in mediacodec(surface) + live TV in that a single surface is reused, while kodi/spmc/mrmc tries to open multiple decoders in parallel during a stream format change.

So, even if the device actually supports multiple decoders, surface fails because the common surface is already in use.
I'll work'on refactoring that...
User avatar
vlaves
Posts: 146
Joined: 04 Dec 2015, 10:33

Re: Stutter when using HW acceleration

Post by vlaves »

koying wrote:There is a design flaw in mediacodec(surface) + live TV in that a single surface is reused, while kodi/spmc/mrmc tries to open multiple decoders in parallel during a stream format change.

So, even if the device actually supports multiple decoders, surface fails because the common surface is already in use.
I'll work'on refactoring that...
Thanks for that quick reply :) So if I use SPMC 16.5.2 still I will not get hardware accelerated Live TV until this gets refactored, right?
Then this refactoring might be merged into MrMC or you are working both together on it?
User avatar
koying
Team MrMC
Posts: 443
Joined: 20 Mar 2016, 17:49

Re: Stutter when using HW acceleration

Post by koying »

Well, it's a bit hit-and-miss.
"Plain" mediacodec should be used as fallback, but that usually doesn't fare well on mpeg2 HD (at least on Shield)
User avatar
vlaves
Posts: 146
Joined: 04 Dec 2015, 10:33

Re: Stutter when using HW acceleration

Post by vlaves »

koying wrote:Well, it's a bit hit-and-miss.
"Plain" mediacodec should be used as fallback, but that usually doesn't fare well on mpeg2 HD (at least on Shield)
Ok, so best I activate both mediacodecs, right? This fallback is for SPMC only or MRMC too?
User avatar
vlaves
Posts: 146
Joined: 04 Dec 2015, 10:33

Re: Stutter when using HW acceleration

Post by vlaves »

@koying and @davilla: Must have been asked for like thousand times, but why you guys don't join forces? Or can this already be considered like the current state? :)

But ment it more like one MrMC and for example with Support for Plugins on the plattforms where it is allowed, like Google Play store for example. But then you would share the player part...just a thought :)
Post Reply