Kodi Community Forum
Linux HOW-TO achieve perfect playback at 23.97 or 59.94 Hz with NVIDIA GPU hardware - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Tips, tricks, and step by step guides (https://forum.kodi.tv/forumdisplay.php?fid=110)
+--- Thread: Linux HOW-TO achieve perfect playback at 23.97 or 59.94 Hz with NVIDIA GPU hardware (/showthread.php?tid=70068)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36


- X3lectric - 2010-09-18

You can now adjust/override the display fps~refresh via advancedsettings.xml like this.
Code:
<advancedsettings>
<video>
  <adjustrefreshrate>
    <override>
      <fpsmin>29.96</fpsmin>
      <fpsmax>30.01</fpsmax>
      <refresh>50</refresh>
    </override>
    <override>
      <fpsmin>23.96</fpsmin>
      <fpsmax>24.01</fpsmax>
      <refresh>24</refresh>
    </override>
    <override>
      <fpsmin>24.99</fpsmin>
      <fpsmax>25.01</fpsmax>
      <refresh>25</refresh>
    </override>
  </adjustrefreshrate>
</video>
</advancedsettings>
If your TV supports 30Hz then choose to override refresh just by changing the <refresh>XX</refresh> or define whatever value you like. If it stutters at a particular fps increase the refresh rate.

This should help you guys and you can thank bobo1on1.

Also if your connected via HDMI the modelines it uses are denoted by CEA-861B Format X? e.g like below
Code:
#  "1920x1080_60_0"     : 1920 x 1080 @ 59.94/60 Hz ([color=Red][b]CEA-861B Format 16[/b][/color])
#  "1920x1080_50"       : 1920 x 1080 @ 50 Hz ([color=Red][b]CEA-861B Format 31[/b][/color])
#  "1920x1080_30"       : 1920 x 1080 @ 29.97/30 Hz ([color=Red][b]CEA-861B Format 34[/b][/color])
#  "1920x1080_25"       : 1920 x 1080 @ 25 Hz ([color=Red][b]CEA-861B Format 33)
[/b][/color]#  "1920x1080_24"       : 1920 x 1080 @ 23.97/24 Hz ([color=Red][b]CEA-861B Format 32[/b][/color])
#  "1920x1080_60i"      : 1920 x 1080 @ 59.94/60 Hz ([color=Red][b]CEA-861B Format 5[/b][/color])
The above shows the modes your TV should support. For 720p TV's your looking for e.g. "1280x720_60_0" : 1280 x 720 @ 59.94/60 Hz (CEA-861B Format 4)


- Superorb - 2010-09-18

^^ Thanks, I'll have to try that. My TV supports 24p and 30p but xbmc only switches to 24p and not 30p.


- X3lectric - 2010-09-18

Ya my TV also supports 30hz problem is cause of this change If I use it the TV wont display it anymore, so idk what xbmc is doing to it. All my 30fps content instead of 30Hz can only be played now at 50Hz or 60Hz using the stuff above... Since TV supports 30Hz and it doesnt display at 30Hz, There has to be something xbmc is doing which is unknow to me so far..


- danz0l - 2010-09-18

Same here. My tv supports 30hz but if its used in xbmc i get a black screen.

# "1920x1080_30" : 1920 x 1080 @ 29.97/30 Hz (CEA-861B Format 34)


- Superorb - 2010-09-18

danz0l Wrote:Same here. My tv supports 30hz but if its used in xbmc i get a black screen.

# "1920x1080_30" : 1920 x 1080 @ 29.97/30 Hz (CEA-861B Format 34)
Well at least xbmc switches your TV, mine doesn't even switch.


- danz0l - 2010-09-18

yes true, thats so weird.


- MdMa - 2010-09-19

X3lectric Wrote:You can now adjust/override the display fps~refresh via advancedsettings.xml like this.

What is the command to get to the advancedsettings.xml?


- fuggin - 2010-09-19

MdMa Wrote:What is the command to get to the advancedsettings.xml?
Depending on your distro:
Code:
locate -i advancesettings.xml
or
Code:
find ~/ -name advancedsettings.xml
then
Code:
vi /home/xbmc/.xbmc/userdata/advancedsettings.xml



- X3lectric - 2010-09-19

or nano


- Superorb - 2010-09-19

X3lectric Wrote:or nano
+1. Nano is much more user friendly than vi.

EDIT: Ok, "find" command doesn't work in my copy of xbmc-live. "sudo find / -name advancedsettings.xml" did nothing, it just jumped to prompt again. Where is this file normally located?

EDIT2: Or does advancedsettings.xml not exist in the default installation?


- bobo1on1 - 2010-09-19

It doesn't exist by default, you have to create it in ~/.xbmc/userdata


- Superorb - 2010-09-19

I was reading the Wiki page for the advancedsettings.xml config file and saw this for the refresh rate overrides:

<!-- NOT available in the Dharma release or any release before that -->

Wasn't Dharma Beta2 just released a few days ago? At least this would explain why it's not working for me.


- jockeihabo - 2010-09-22

JumJum, thanks alot! I've worked on this for days, my GF almost got nuts of me always trying to get this right. I tried every setting before I stumbled over this script. Now it works so fine. First i did something wrong and had to restore the dispaly settings in safe mode, but the second time it worked. Again, thanks a lot!


thank you! - vanbordunk - 2010-09-22

I cannot begin to explain how much time this has saved me - I started out a couple years ago with xbmc on an old xbox and now I'm using a pc with xbmc-live.

This script has saved me hours of frustration and should be included in the live iso somehow.

again, thank you so very much!


- Celox - 2010-10-05

hi in the first post of the guide its mentioned.

Quote:"The first mode on the line will be your default mode. In my case it looks like this when done:"

I want my default for the menu to be "1920x1080_24_0"

so my mode line looks like this:

Code:
Modes "1920x1080_24_0" "1920x1080_60_0"

when i check after applying the changes (xbmc->settings->systems) it still says "60", if i change it to "24" the resolution gets changed to "640x480" even though i set the config to be "1920x1080_24_0".

I want to avoid the screen going black for a split second while changing from video playback to menu. (which happens if you watch a movie@24fps and switch to menu which is @60fps)

my tv supports the following modes
Code:
--- Modes in ModePool for SAMSUNG (DFP-1) ---
"nvidia-auto-select" : 1920 x 1080 @  60.0 Hz  (from: EDID)
"1920x1080"          : 1920 x 1080 @  60.0 Hz  (from: EDID)
"1920x1080_60"       : 1920 x 1080 @  60.0 Hz  (from: EDID)
"1920x1080_60_0"     : 1920 x 1080 @ 59.94/60 Hz (CEA-861B Format 16) (from: EDID)
"1920x1080_50"       : 1920 x 1080 @ 50 Hz (CEA-861B Format 31) (from: EDID)
"1920x1080_30"       : 1920 x 1080 @ 29.97/30 Hz (CEA-861B Format 34) (from: EDID)
"1920x1080_25"       : 1920 x 1080 @ 25 Hz (CEA-861B Format 33) (from: EDID)
"1920x1080_24"       : 1920 x 1080 @ 23.97/24 Hz (CEA-861B Format 32) (from: EDID)
"1920x1080_60i"      : 1920 x 1080 @ 59.94/60 Hz (CEA-861B Format 5) (from: EDID)
"1920x1080_50i"      : 1920 x 1080 @  50.0 Hz Interlace  (from: EDID)
"1280x720"           : 1280 x  720 @  60.0 Hz  (from: EDID)
"1280x720_60"        : 1280 x  720 @  60.0 Hz  (from: EDID)
"1280x720_60_0"      : 1280 x  720 @ 59.94/60 Hz (CEA-861B Format 4) (from: EDID)
"1280x720_50"        : 1280 x  720 @  50.0 Hz  (from: EDID)
"720x576"            :  720 x  576 @ 50 Hz (CEA-861B Format 18) (from: EDID)
"720x576_50"         :  720 x  576 @ 50 Hz (CEA-861B Format 18) (from: EDID)
"720x480"            :  720 x  480 @  59.9 Hz  (from: EDID)
"720x480_60"         :  720 x  480 @  59.9 Hz  (from: EDID)
"640x480"            :  640 x  480 @  60.0 Hz  (from: EDID)
"640x480_60"         :  640 x  480 @  60.0 Hz  (from: EDID)
--- End of ModePool for SAMSUNG (DFP-1):

this is how my xorg.conf looks like:
Code:
Section "Device"
        Identifier "nvidia"
        Driver  "nvidia"
        Option  "NoLogo"              "true"
        Option  "DynamicTwinView"     "false"                            # Enable 1080p 24Hz
        Option  "NoFlip"              "false"
        Option  "FlatPanelProperties" "Scaling = Native"
        Option  "ModeValidation"      "NoVesaModes, NoXServerModes"
        Option  "UseDisplayDevice"    "DFP-1"
        Option  "ModeDebug"           "true"
        Option  "HWCursor"            "false"                            # Blinking Cursor Fix
        Option  "OnDemandVBlankInterrupts" "true"                        # fix nvidia interrupts in 2D
        Option  "Coolbits" "1"
        Option  "RegistryDwords" "PowerMizerEnable=0x1; PerfLevelSrc=0x2222; PowerMizerLevel=0x3; PowerMizerDefault=0x3; PowerMizerDefaultAC=0x3"
EndSection

Section "Screen"
        Identifier      "screen"
        Device          "nvidia"
        SubSection      "Display"
        Modes "1920x1080_24_0" "1920x1080_60_0"
        EndSubSection
EndSection

Section "Extensions"
        Option  "Composite"           "false" # Disable Composite for better H264 acceleration
EndSection

any idea whats wrong im all confused :confused2:

Edit1:
argh!! sorry i found the error, i think i had to much coffee this morning xD.
i included "Modes "1920x1080_24_0"" but my display supports only "Modes "1920x1080_24"
thanks to the debugging in xorg.log! said "no valid mode for..."

btw great guide thx!

Edit2:
hmm i just noticed mine says:
Code:
NVIDIA(0): "1920x1080_24"       : 1920 x 1080 @ 23.97/24 Hz (CEA-861B Format 32) (from: EDID)

looking at your philips tv modes:
Code:
"1920x1080_24_0"     : 1920 x 1080 @ 23.97/24 Hz (CEA-861B Format 32) (from: EDID)

wouldn't those be identical? just curious?