Disabled capturing when changing resolution.

Might be off here, but without capturing it seems like we get a
behaviour closer to that of the PC.
This commit is contained in:
Olle Håkansson 2014-04-20 23:15:56 +02:00 committed by thefiddler
parent 50ed0ee9da
commit 7c3872531e

View file

@ -161,10 +161,10 @@ namespace OpenTK.Platform.MacOS
if (width == resolution.Width && height == resolution.Height && bpp == resolution.BitsPerPixel && System.Math.Abs(freq - resolution.RefreshRate) < 1e-6) if (width == resolution.Width && height == resolution.Height && bpp == resolution.BitsPerPixel && System.Math.Abs(freq - resolution.RefreshRate) < 1e-6)
{ {
if (displaysCaptured.Contains(display) == false) // if (displaysCaptured.Contains(display) == false)
{ // {
CG.DisplayCapture(display); // CG.DisplayCapture(display);
} // }
Debug.Print("Changing resolution to {0}x{1}x{2}@{3}.", width, height, bpp, freq); Debug.Print("Changing resolution to {0}x{1}x{2}@{3}.", width, height, bpp, freq);
@ -186,7 +186,7 @@ namespace OpenTK.Platform.MacOS
Debug.Print("Restoring resolution."); Debug.Print("Restoring resolution.");
CG.DisplaySwitchToMode(display, storedModes[display]); CG.DisplaySwitchToMode(display, storedModes[display]);
CG.DisplayRelease(display); //CG.DisplayRelease(display);
displaysCaptured.Remove(display); displaysCaptured.Remove(display);
return true; return true;