Linux Kodi sets wrong refresh rate
#1
Hi guys,

first up my system:

Linux Mint 17.3 Mate
Intel Pentium 4400
Nvidia GeForce 950
Kodi 16.1 Jarvis
Screen: 3840x2160 @ 60p (4k)


Good:

To avoid stuttering I enabled the option "Change Display Refresh Rate at Start/Stop" so it best matches any video file's frame rate.


Example:
My PC boots up and starts with 60p for desktop use, I launch Kodi and watch a movie with 23,975p and Kodi changes the refresh rate of the display accordingly - the movie looks very smooth and everything is fine.


Problem:

BUT when I watch a movie witch has a 25p frame rate Kodi does something odd: It changes the display refresh rate to 50p. Obviously there is a mismatch and the video is stuttering. I checked by pressing "O" during playback and I could confirm that the display runs at 50p while the movie only delivers 25p. There are skipped frames which cause the stuttering.

I also checked the log-file: Kodi recognises the movie goes with 25p, but it calls XRANDR (the display manager) and sets 50p for the display.

And another thing I tried: I disabled the Kodi automated refresh-rate change option; closed Kodi and called XRANDR manually to force my display to 25p, then I launched Kodi again and watched the same movie file that comes with 25p: Guess what, it was smooth as butter!

My guess for a solution would be: I should change the value from 50p to 25p when facing a 25p movie file, but i don't know how.


Is this a well known bug; is there a fix? Please help!
Reply
#2
Kodi does what's expected. 50hz is an integer of 25, so the only stuttering you see is what is already inherent in 25fps videos. Your display probably doesn't support 25hz anyways, because as long as 50hz is supported then it doesn't matter.
Reply
#3
Sorry to contradict:

When I call XRANDR without any arguments it lists all available modes for my Display, 25p is among them.

When I force my Display with

Code:
xrandr --output HDMI-2 --rate 25

and disable the "auto refresh rate change" before in Kodi the stuttering disapears!


Huh
Reply
#4
We use the highest refreshrate available that fits linear to Video fps. So 50 for 25.

Post a Debug Log please of the affected file.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#5
I will post it when I am home from work Smile pls stay tuned!
Reply
#6
OK here we go:

The log-file LOG

First I launched the movie with 25p (kodi forces to 50p and I can see stutter)
Second I launched a movie with 23,98p and kodi forces respectively (smooth as butter)


By the way I called xrandr and my display supports the following modes:

Code:
3840x2160      60.0 +   59.9     50.0     30.0     25.0     24.0

So when Kodi forces 23,98p as the log says, the display is actually running at 24.0 ?

Thanx so far guys
Reply
#7
I wanted to have:

25p movie with 50 hz
25p movie with 25 hz please

Edit: Your log was not a Debug Log - so nothing of interest in there, sadly.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#8
Please also provide: /usr/lib/kodi/kodi-xrandr | pastebinit

As you play 1080p movie which is then upscaled to 2160p it might be that the scaling shader used is too slow and introduces that stuttering. What scaling method are you using?
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#9
Sorry to be slow today so you want a log file for each scenario? ok here we go:

I force 50hz and play a 25p video:

http://pastebin.com/pMkqjDAM


I force 25hz with 25p

http://pastebin.com/KCGKNLa7

the command
Code:
/usr/lib/kodi/kodi-xrandr | pastebinit

gives

Code:
Bad API request, invalid api_dev_key

as result.


Honestly: I don't know which scaling option I am actually using. I just set the display resolution and resolution in Kodi and let it handle the rest.


EDIT
what I noticed:
when I go with 50hz the first frame of the movie stays half black (upper half of screen) for like 1,5 seconds. after that the movie starts to run. with 25hz this effect can not be seen
Reply
#10
DISPLAY=:0 /usr/lib/kodi/kodi-xrandr | pastebinit

Quote:20:41:35 T:140102983133248 NOTICE: Disabled debug logging due to GUI setting. Level 0.

^^ sadly again not a Debug Log
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#11
haha ok got it sorry again

next try this evening Wink
Reply

Logout Mark Read Team Forum Stats Members Help
Kodi sets wrong refresh rate0