Module: wine
Branch: master
Commit: 967a49fcb24493dafe9c39ffa49eee3f2bea87e8
URL: http://source.winehq.org/git/wine.git/?a=commit;h=967a49fcb24493dafe9c39ffa…
Author: Ken Thomases <ken(a)codeweavers.com>
Date: Tue Jul 2 01:25:00 2013 -0500
winemac: Force swap interval to 0 for single-buffered contexts to avoid vsync'ed flushes.
---
dlls/winemac.drv/opengl.c | 14 +++++++++++---
1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/dlls/winemac.drv/opengl.c b/dlls/winemac.drv/opengl.c
index 904158b..69f94e2 100644
--- a/dlls/winemac.drv/opengl.c
+++ b/dlls/winemac.drv/opengl.c
@@ -2901,7 +2901,9 @@ static BOOL macdrv_wglSwapIntervalEXT(int interval)
return FALSE;
}
- if (interval > 1)
+ if (!pixel_formats[context->format - 1].double_buffer)
+ interval = 0;
+ else if (interval > 1)
interval = 1;
value = interval;
@@ -3238,8 +3240,14 @@ static BOOL create_context(struct wgl_context *context, CGLContextObj share)
}
/* According to the WGL_EXT_swap_control docs, the default swap interval for
- a context is 1. CGL contexts default to 0, so we need to set it. */
- swap_interval = 1;
+ a context is 1. CGL contexts default to 0, so we need to set it. This
+ only make sense for double-buffered contexts, though. In theory, for
+ single-buffered contexts, there's no such thing as a swap. But OS X
+ will synchronize flushes of single-buffered contexts if this is set. */
+ if (pf->double_buffer)
+ swap_interval = 1;
+ else
+ swap_interval = 0;
err = CGLSetParameter(context->cglcontext, kCGLCPSwapInterval, (GLint*)&swap_interval);
if (err != kCGLNoError)
WARN("CGLSetParameter(kCGLCPSwapInterval) failed with error %d %s; leaving un-vsynced\n", err, CGLErrorString(err));
Module: wine
Branch: master
Commit: b0a3d93400f90a06da8ba314ed37a9e2b75a9293
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b0a3d93400f90a06da8ba314e…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru>
Date: Tue Jul 2 10:24:23 2013 +0900
kernel32/tests: Fix a couple of typos.
---
dlls/kernel32/tests/virtual.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/kernel32/tests/virtual.c b/dlls/kernel32/tests/virtual.c
index 521ce6e..e605242 100644
--- a/dlls/kernel32/tests/virtual.c
+++ b/dlls/kernel32/tests/virtual.c
@@ -712,8 +712,8 @@ static void test_MapViewOfFile(void)
ok(info.BaseAddress == ptr, "BaseAddress should have been %p but was %p instead\n", ptr, info.BaseAddress);
ok(info.AllocationBase == ptr, "AllocationBase should have been %p but was %p instead\n", ptr, info.AllocationBase);
ok(info.RegionSize == 0x10000, "RegionSize should have been 0x10000 but was 0x%lx\n", info.RegionSize);
- ok(info.State == MEM_COMMIT, "State should have been MEM_RESERVE instead of 0x%x\n", info.State);
- ok(info.Protect == PAGE_READONLY, "Protect should have been 0 instead of 0x%x\n", info.Protect);
+ ok(info.State == MEM_COMMIT, "State should have been MEM_COMMIT instead of 0x%x\n", info.State);
+ ok(info.Protect == PAGE_READONLY, "Protect should have been PAGE_READONLY instead of 0x%x\n", info.Protect);
if (info.Type == MEM_PRIVATE) /* win9x is different for uncommitted mappings */
{
ok(info.AllocationProtect == PAGE_NOACCESS,