Detect doublebuffered visuals on Mac OS X.
authorJosé Fonseca <jose.r.fonseca@gmail.com>
Mon, 5 Dec 2011 08:32:56 +0000 (08:32 +0000)
committerJosé Fonseca <jose.r.fonseca@gmail.com>
Mon, 5 Dec 2011 08:33:34 +0000 (08:33 +0000)
driver.py

index 27eef97074db66b0358ba78045b063abeb352baa..1c4904cc24b335f3672e846386ac4fd707ce89ce 100755 (executable)
--- a/driver.py
+++ b/driver.py
@@ -131,7 +131,8 @@ class TraceChecker:
             if mo:
                 self.call_no = int(mo.group(1))
                 function_name = mo.group(2)
-                if function_name.find('SwapBuffers') != -1:
+                if function_name.find('SwapBuffers') != -1 or \
+                   line.find('kCGLPFADoubleBuffer') != -1:
                     swapbuffers += 1
                 if function_name in ('glFlush', 'glFinish'):
                     flushes += 1