From: Foo Bar <f...@bar.com> Interlaced modes generally have an odd VTotal, so we lose half a line from VTotal when we divide by two. That causes the final refresh rate to be slightly off. Make VTotal a double to avoid the problem.
Signed-off-by: Foo Bar <f...@bar.com> --- xrandr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xrandr.c b/xrandr.c index 9467c29..f94cfab 100644 --- a/xrandr.c +++ b/xrandr.c @@ -541,7 +541,7 @@ static double mode_refresh (XRRModeInfo *mode_info) { double rate; - unsigned int vTotal = mode_info->vTotal; + double vTotal = mode_info->vTotal; if (mode_info->modeFlags & RR_DoubleScan) { /* doublescan doubles the number of lines */ -- 1.8.1.5 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev