I have been knowing that MX Player stutters when playing some video file through HTTP streaming from a file manager app that converts SMB to HTTP, but not when playing the same file from local storage. I posted a question about that [Q]Stutters only while streaming (probably NOT the bandwidth issue).
I have been so annoyed by this problem, and tried to find out why. So, I created my own streaming application that launches MX Player or VLC Player. For some files, VLC had no problems but MX Player stuttered. The problem seems to be that MX Player is continuously making a lot of HTTP requests with back and forth ranges. For example, the requested ranges are like the following.
Range: bytes=0-
Range: bytes=308216864-
Range: bytes=36-
Range: bytes=31734357-
Range: bytes=555441-
Range: bytes=31734374-
Range: bytes=557632-
...and so on
Click to expand...
Click to collapse
MX Player sent about 400 range requests during about 15 seconds. These requests seem very unnecessary and caused CPU usage spike. I think the high CPU usage might be the cause of the stuttering. When the SMB to HTTP server was runing on my computer, not on the Android device, MX Player made the same amount of range requests but did not stutter. The HTTP server in either case is the same thing because I wrote it from scratch using Java.
VLC did not make these back and forth range requests for the same video file. VLC only made 3 range requests during the same period.
Please see the attached logs for full request/response details. I started playing the mp4 file from the beginning, and left it for about 15 seconds, and I did NOT manually seek the video.
Why is MX Player doing this?
Related
Bug Description:
When resuming playback, double audio occurs (few ms delay on the echo/replay).
It does not happen when playing from the beginning and seeking.
Seeking, play/pause and changing render from hw, hw+, soft do not make a difference.
The only way to avoid the issue is to not resume playback, start from the beginning and seek to where it last was.
Environment:
I run MX Player off a Hisense Android 4.2.2 TV.
I use BubbleUPnP to offer network access to my media, I do not transcode since MX Supports the native formats.
I use Universal Media Server as the UPnP source
htmltag said:
Bug Description:
When resuming playback, double audio occurs (few ms delay on the echo/replay).
It does not happen when playing from the beginning and seeking.
Seeking, play/pause and changing render from hw, hw+, soft do not make a difference.
The only way to avoid the issue is to not resume playback, start from the beginning and seek to where it last was.
Environment:
I run MX Player off a Hisense Android 4.2.2 TV.
I use BubbleUPnP to offer network access to my media, I do not transcode since MX Supports the native formats.
I use Universal Media Server as the UPnP source
Click to expand...
Click to collapse
This looks like a device specific issue, I will try to contact device manufacturer.
Also if you would contact Hisense as a customer, we may have better chances to make them check if it is a device bug.
Thanks
Using MXPlayer v1.9.6 on Marshmallow.
Others on reddit and I have noticed that when you pause a streaming video and restart it, it plays a few seconds and then the video ends. I think it might be a buffering issue.
oroboros74 said:
Using MXPlayer v1.9.6 on Marshmallow.
Others on reddit and I have noticed that when you pause a streaming video and restart it, it plays a few seconds and then the video ends. I think it might be a buffering issue.
Click to expand...
Click to collapse
Kindly provide a bug report. Without a proper bug report, it's very difficult to identify the issue.
I have the same issue. Statement above, is clear. When streaming, if you press pause, MX PLAYER will try to Load; Stop; and End Playback.
Version 1.9.10(ARMv7 neon)
Running on Firestick (version 2, 4 gigs available)
mx player, Standard config.
Mp4 file ~500MB 720p max.(can be smaller or much larger makes no difference)
having trouble making a bug report because it is on a Firestick, however I did not always have this problem. Any help to point me and others in the right direction would be greatly appreciated, please.
Koffeeshop77 said:
I have the same issue. Statement above, is clear. When streaming, if you press pause, MX PLAYER will try to Load; Stop; and End Playback.
Version 1.9.10(ARMv7 neon)
Running on Firestick (version 2, 4 gigs available)
mx player, Standard config.
Mp4 file ~500MB 720p max.(can be smaller or much larger makes no difference)
having trouble making a bug report because it is on a Firestick, however I did not always have this problem. Any help to point me and others in the right direction would be greatly appreciated, please.
Click to expand...
Click to collapse
Without a bug report or log, it's very difficult to understand the actual issue. The issue might be with the server. When you resume the video, MX Player will try to reconnect. If the reconnection is refused, then MX Player will fail to play & close the playback.
MX player
I'm having a problem with ...I'm having a problem with the video taking forever to load, then when it loads and buffer, plays for a little bit then begins pause and buffer then play, and so on..This happens the WHOLE time.I'm wondering, what do I need to do in order to get the buffering to stop so I may watch the video in full?
nazim29 said:
I'm having a problem with ...I'm having a problem with the video taking forever to load, then when it loads and buffer, plays for a little bit then begins pause and buffer then play, and so on..This happens the WHOLE time.I'm wondering, what do I need to do in order to get the buffering to stop so I may watch the video in full?
Click to expand...
Click to collapse
1) your Wi-Fi connection is to slow, you also can't be too far away, WiFi it's being blocked by something metal(tv, cable receiver, pc, speakers, giant fish tank?,...)
2) your internet is being used by other members of the household
3) your running out of RAM or trying to stream to high of quality than your device can handle(use "clean master" to boost your performance before streaming)
4)AND MOST LIKELY, the server you are streaming from is slow, choose diff server, better compression size(e.g. 850MB instead of 2GB) or lower your quality choice 480/720p instead of 1080 or above.
5) your internet connection is slow from ISP e.g. 1500mbps instead of 5000mbps+.
^^WOULD RECOMMEND performing a internet speed test, to see where you stand on most of the above^^
I hope that helps you Nazim. In my case it has always been a slow server. And clean master helps alot if I'm using a low ram tv box/smart TV.
I have a 2015 model of sony bravia android tv, and it has a MT5890 CPU and a mali T-624 GPU. I installed the latest version of mx player and armv7 neon codec.
I am able to play x265 coded videos with built-in video player without any problem, it's very smooth, and I can skip forward or backward or just jump to whenever I wish to.
However when using mx player, it's also very smooth, but I can only play from the beginning, if I try to skip forward or backward, or jump to a certain time point, it starts to act very weird. Sometimes video speeds up 2x or 3x, sometimes it slows down, like it's catching up or slowing down to wait audio to be synchronized. And it can take from couple of minutes to half an hour to go back to normal.
This only applies to x265 coded videos, I have other video that are coded with x264 or HEVC, and they work just fine in both built-in player and mx player.
I have tried other video players like spmc, kodi or VLC, they all stutter, VLC is probably the best among these but it is still dropping frames left and right. But most of them don't have problem with skipping or jumping.
Can someone please explain the reason? Could it be fixed?
Much appreciated!
terrytw said:
I have a 2015 model of sony bravia android tv, and it has a MT5890 CPU and a mali T-624 GPU. I installed the latest version of mx player and armv7 neon codec.
I am able to play x265 coded videos with built-in video player without any problem, it's very smooth, and I can skip forward or backward or just jump to whenever I wish to.
However when using mx player, it's also very smooth, but I can only play from the beginning, if I try to skip forward or backward, or jump to a certain time point, it starts to act very weird. Sometimes video speeds up 2x or 3x, sometimes it slows down, like it's catching up or slowing down to wait audio to be synchronized. And it can take from couple of minutes to half an hour to go back to normal.
This only applies to x265 coded videos, I have other video that are coded with x264 or HEVC, and they work just fine in both built-in player and mx player.
I have tried other video players like spmc, kodi or VLC, they all stutter, VLC is probably the best among these but it is still dropping frames left and right. But most of them don't have problem with skipping or jumping.
Can someone please explain the reason? Could it be fixed?
Much appreciated!
Click to expand...
Click to collapse
Basically, x265 is an encoder for HEVC. So, both are same.
Maybe some particular HEVC profile has issues. Can you try HW+ decoder?
Thirumalai.K said:
Basically, x265 is an encoder for HEVC. So, both are same.
Maybe some particular HEVC profile has issues. Can you try HW+ decoder?
Click to expand...
Click to collapse
In fact I am using HW+ decoder, and it's the only way I can play those videos smoothly. Switching to HW or SW would make the video either completely unplayable or stutter very heavily.
To sum it up, I CAN play any videos with built-in player smoothly and drag or jump or skip however I want to.
I CAN play x265 coded files smoothly with mx player in HW+ mode, but I CANNOT jump or skip. I CAN play any other videos with mx player without any problem.
I CAN play x265 coded files with some level of stutter with other players like spmc and VLC, but I CAN drag or jump however I want to.
The videos that I am having problem with have these kind of parameters:
Format : HEVC
Format Info : High Efficiency Video Coding
Format profile : Main [email protected]@High
Codec ID : V_MPEGH/ISO/HEVC
Writing library : x265 2.5+4-b4a5bcfe29c7:[Windows][GCC 4.9.3][64 bit] 10bit
If the writing library is x264 or ATEME Titan KFE or ATEME Titan file, or if the codec ID is hev1, or if the format profile is Main [email protected]@Main, I don't have a problem.
This is so weird....
To the TC - Did you ever get this sorted?
I am having the same issue on my Sony Bravia. Whilst the actual player is exactly what I wanted, I get exactly the same issue when fast forwarding or rewinding.
I have played around with the different codec settings but it doesn't seem to make any differences.
Did you end up finding a solution?
Cheers
littlelostkiwi said:
To the TC - Did you ever get this sorted?
I am having the same issue on my Sony Bravia. Whilst the actual player is exactly what I wanted, I get exactly the same issue when fast forwarding or rewinding.
I have played around with the different codec settings but it doesn't seem to make any differences.
Did you end up finding a solution?
Cheers
Click to expand...
Click to collapse
Glad to see that I am not alone. But unfortunately I did not find any solution and had given up on this.
After all, it is only a tiny fraction of all the videos have this kind of behavior.
Thank you for the confirmation
Hi, thank you for MX player.
Used it for years, simply a great product
I'm currently working on a http-server project and it streams to a lot of media-players.
My server works perfectly with for instance Kodi and alot of other streamers.
I wonder how MX player handles seeks in a HTTP-stream?
My server sends the header to MX player: Accept-Ranges: bytes
MX sends to me: Range: bytes=0-
My server then with correct headers:
Content-Range: bytes 0-10561452647/10561452647
Content-Length: 10561452648
If I seek in MX the next GET-request for the file does not contain the: Range: bytes=x-
With information above MX should have what is needed to request for instance 50% in the stream?
Range: bytes=5280726324-
Trying to figure out if this is a server-issue or a MX-player issue.
Any tips?
Edit:
I have investigated further and found MX seeks perfectly when using the HW+ or SW decoder.
The seek does not work when you are using the HW-decoder.
Does anyone know if this is a bug or restriction in the decoder?
largie said:
Hi, thank you for MX player.
Used it for years, simply a great product
I'm currently working on a http-server project and it streams to a lot of media-players.
My server works perfectly with for instance Kodi and alot of other streamers.
I wonder how MX player handles seeks in a HTTP-stream?
My server sends the header to MX player: Accept-Ranges: bytes
MX sends to me: Range: bytes=0-
My server then with correct headers:
Content-Range: bytes 0-10561452647/10561452647
Content-Length: 10561452648
If I seek in MX the next GET-request for the file does not contain the: Range: bytes=x-
With information above MX should have what is needed to request for instance 50% in the stream?
Range: bytes=5280726324-
Trying to figure out if this is a server-issue or a MX-player issue.
Any tips?
Edit:
I have investigated further and found MX seeks perfectly when using the HW+ or SW decoder.
The seek does not work when you are using the HW-decoder.
Does anyone know if this is a bug or restriction in the decoder?
Click to expand...
Click to collapse
HI,
HW+ & SW are MX Player's own implementations. Whereas HW decoder is just a wrapper for android mediaplayer API. So, MX ony has basic controls. If any errors on it, generally it's from the mediaplayer implementation on the device itsellf.
Some old android versions do not support seeking of ts videos. Not sure is it the case of yours.
We can understand it better if you can provide a bug report which is colllected immediately after the issue (from MX's help menu)
Good afternoon,
MX Player (Pro, latest version on a A8 under oreo) skips several seconds of the beginning of MPEG-TS videos streamed from a HTTP server using chunked transfer encoding. I have tried with many contents, and different video and audio codecs, and each time, between a few and a dozen of seconds were not played. Remuxing the file to mp4 or distributing it from a server using another method of transfer solved the issue.
I have checked that there was no problem with the files or the server, as they all play fine on a PC under any software.
So the problem is likely to be specific to MX Player and .ts videos (it is the container used by DVB broadcasting in the country where I live) read from a server relying on chunked transfer encoding.
Thanks in advance.