PDA

View Full Version : Adjust refresh rate - New Video Player setting?


Hitcher
2008-11-16, 23:32
Just got SVN version 19205 and I noticed there's is a new option in the Video Player settings that wasn't there before called 'Adjust refresh rate'.

http://img510.imageshack.us/img510/3426/screenshot000tw9.png

What does it do exactly?

jmarshall
2008-11-16, 23:52
It adjusts the refresh rate of the screen to match the video. Perhaps the string needs to be extended with:

"of screen to match the video"

ashlar
2008-11-16, 23:56
It adjusts the refresh rate of the screen to match the video. Perhaps the string needs to be extended with:

"of screen to match the video"
According to what logic? How does it adjust the refresh rate?

tslayer
2008-11-16, 23:57
Based on refresh of video being played.

tslayer
2008-11-16, 23:58
Oh, and I believe only on Linux. Elupus, correct me if I am wrong.

ashlar
2008-11-17, 00:03
Based on refresh of video being played.Ok, but I'm sorry to repeat myself... according to what logic.

If a movie has 23.976 fps and you have a 48Hz display refresh rate available, will XBMC pick that? If you have just 60Hz, what will it do?

Hitcher
2008-11-17, 00:03
Oh, and I believe only on Linux. Elupus, correct me if I am wrong.

That would explain why I don't see any difference in FPS between it being On or Off then.

ashlar
2008-11-17, 00:12
http://xbmc.org/trac/ticket/4902

It doesn't alter dinamically the frame rate as Reclock does, it simply picks the refresh rate closest to the frame rate, if I'm not mistaken.

Still, sad to see it only on Linux, for now. My experiments with Ubuntu ended up less than successfully.

Nothing on this http://xbmc.org/trac/ticket/5307 unfortunately. :sniffle:

jmarshall
2008-11-17, 00:18
If you want the logic, read the code:


// Find closest refresh rate
for (int i = (int)CUSTOM; i<(CUSTOM+g_videoConfig.GetNumberOfResolutions()) ; i++)
{
RESOLUTION_INFO &curr = g_settings.m_ResInfo[m_iResolution];
RESOLUTION_INFO &info = g_settings.m_ResInfo[i];

if (info.iWidth != curr.iWidth
|| info.iHeight != curr.iHeight)
continue;

int c_weight = (int)(1000 * fmodf(curr.fRefreshRate, fps) / curr.fRefreshRate);
int i_weight = (int)(1000 * fmodf(info.fRefreshRate, fps) / info.fRefreshRate);

// Closer the better, prefer higher refresh rate if the same
if ((i_weight < c_weight)
|| (i_weight == c_weight && info.fRefreshRate > curr.fRefreshRate))
m_iResolution = (RESOLUTION)i;
}


fps is the input framerate.

Cheers,
Jonathan

Hitcher
2008-11-17, 00:32
Added in r16196 with some modifications to make sure it selects 59.94 instead of 29.97 for 23,97 clips.

That proves it's not yet working for Windows for me - any idea when it will be?

jmarshall
2008-11-17, 00:44
When someone does code to:

1. Get the refresh rate of the current video mode.
2. Set the refresh rate of the current video mode.

As far as I am aware, this is not possible through SDL, so we'd have to use some other method.

Cheers,
Jonathan

Hitcher
2008-11-17, 00:52
Thanks for the reply.

PantsOnFire
2008-11-17, 02:04
Is this the same thing as 'shearing' ?

I have the Atlantis 8.10 final and even though I have my settings set to:
(Vertical Blank Sync always enabled)

I still get tearing in my movies.

Can I fix this somehow?

Livin
2008-11-17, 02:38
Is this the same thing as 'shearing' ?

I have the Atlantis 8.10 final and even though I have my settings set to:
(Vertical Blank Sync always enabled)

I still get tearing in my movies.

Can I fix this somehow?

try a newer build

PantsOnFire
2008-11-17, 03:02
try a newer build

I am using the build from here:
http://downloads.sourceforge.net/xbmc/XBMC_for_Windows-8.10.exe?use_mirror=

(the newest build?)
or is there a newer build than this?

Livin
2008-11-17, 03:20
yes

look in the forum stickies

reading is fun-dum-mental :P

PantsOnFire
2008-11-17, 03:49
Tried it, same problem :p

Louike
2008-11-17, 22:28
fingers crossed, i hope this works out for the windows release

olympia
2008-11-19, 23:20
Is there any way to check current refresh rate while playing a movie?
That stats involed by the "o" key on the keyboard doesn't provide this info (would be great)

CapnBry
2008-11-19, 23:28
I think we're reaching a consensus in another thread about how resolution and framerate switching should work and be stored internally, so this will come after that is nailed down.

For my own information though: folks which want adjusting of refresh rate, I'm assuming your display device is a television over DVI/HDMI right? What kind of options show up in the windows display resolution dialog? I mean do you get 1280x720@24, 1280x720@30, and 1280x720@60 etc?

davilla
2008-11-19, 23:37
I think we're reaching a consensus in another thread about how resolution and framerate switching should work and be stored internally, so this will come after that is nailed down.

For my own information though: folks which want adjusting of refresh rate, I'm assuming your display device is a television over DVI/HDMI right? What kind of options show up in the windows display resolution dialog? I mean do you get 1280x720@24, 1280x720@30, and 1280x720@60 etc?

Just an FYI here, sometime the info retrieved from the Monitor is just pain wrong. It's a big problem under the Linux world so this is an area where one has to program defensively. Just something to think about..

CapnBry
2008-11-20, 00:04
Is there any way to check current refresh rate while playing a movie?
That stats involed by the "o" key on the keyboard doesn't provide this info (would be great)The screen refresh rate or the playback frame rate? The screen refresh rate isn't shown anywhere but it can be added to the "Video Mode Info" display, the one shown when you cycle zoom modes if you patch thuslyIndex: xbmc/GUIWindowFullScreen.cpp
================================================== =================
--- xbmc/GUIWindowFullScreen.cpp (revision 16233)
+++ xbmc/GUIWindowFullScreen.cpp (working copy)
@@ -651,7 +651,10 @@
int iResolution = g_graphicsContext.GetVideoResolution();
{
CStdString strStatus;
- strStatus.Format("%ix%i %s", g_settings.m_ResInfo[iResolution].iWidth, g_settings.m_ResInfo[iResolution].iHeight, g_settings.m_ResInfo[iResolution].strMode);
+ strStatus.Format("%s %ix%i@%.2fHz %s",
+ g_localizeStrings.Get(13287), g_settings.m_ResInfo[iResolution].iWidth,
+ g_settings.m_ResInfo[iResolution].iHeight, g_settings.m_ResInfo[iResolution].fRefreshRate,
+ g_settings.m_ResInfo[iResolution].strMode);
CGUIMessage msg(GUI_MSG_LABEL_SET, GetID(), LABEL_ROW3);
msg.SetLabel(strStatus);
OnMessage(msg);
Should I submit a ticket for this? Seems like it would be nice to have this info and look I even used existing localization!

jmarshall
2008-11-20, 00:22
I'll add it now :)

olympia
2008-11-20, 00:29
WOW, Guys, that was fast :D
Thank you!!

edit:
However, If I upgrade to the latest SVN version on Live (using the svn repo), I only get SVN:16188, which doesn't include this feature... What am I doing wrong?

ashlar
2008-11-20, 02:04
For my own information though: folks which want adjusting of refresh rate, I'm assuming your display device is a television over DVI/HDMI right? What kind of options show up in the windows display resolution dialog? I mean do you get 1280x720@24, 1280x720@30, and 1280x720@60 etc?I connect through VGA and I created custom resolutions for 1366x768@24, 1366x768@48, 1366x768@50 and 1366x768@60 in Nvidia control panel.

CapnBry
2008-11-20, 03:42
However, If I upgrade to the latest SVN version on Live (using the svn repo), I only get SVN:16188, which doesn't include this feature... What am I doing wrong?
Good question. It went in in r16241, are you on the right branch? Try running svn info in the top level directory and make sure the url is https://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/linuxport/XBMC

Unless I'm missing something about what you mean by "Live" ???

And thanks ashlar, I dragged my TV into my office and hooked it up and I'm trying to get some other resolutions and refreshes to it for testing. ATI's CCC seems to only want to give me 60Hz on it though. Damn you ATI, you will do what I desire!

tslayer
2008-11-20, 03:43
You are using the repo. Use svn instead and build yourself.

The repo is only a nightly thing I believe.

olympia
2008-11-20, 22:02
Can this be done on XBMC Live?
I don't have found any info on this. And it seems the standard Linux build instructions are removed (if it at all would be applicable)

Thanks!

ashlar
2008-11-21, 00:01
And thanks ashlar, I dragged my TV into my office and hooked it up and I'm trying to get some other resolutions and refreshes to it for testing. ATI's CCC seems to only want to give me 60Hz on it though. Damn you ATI, you will do what I desire!Try Powerstrip, that's guaranteed to work well with ATI cards.