From 07296e74cb7e1ead93ce1fb2cf75fcb3988e5072 Mon Sep 17 00:00:00 2001 From: Levent Duivel Date: Fri, 8 Nov 2024 01:30:55 +0500 Subject: [PATCH] small fix --- screendump/FrameUpdater.m | 3 +-- screendump/ScreenDumpVNC.m | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/screendump/FrameUpdater.m b/screendump/FrameUpdater.m index c925f21..8498585 100644 --- a/screendump/FrameUpdater.m +++ b/screendump/FrameUpdater.m @@ -67,8 +67,7 @@ [self stopFrameLoop]; _updatingFrames = YES; dispatch_async(dispatch_get_main_queue(), ^(void){ - // TODO: can we make VSync happen here? - _updateFrameTimer = [NSTimer scheduledTimerWithTimeInterval:1/500 target:self selector:@selector(_updateFrame) userInfo:nil repeats:YES]; + _updateFrameTimer = [NSTimer scheduledTimerWithTimeInterval:1/400 target:self selector:@selector(_updateFrame) userInfo:nil repeats:YES]; }); } diff --git a/screendump/ScreenDumpVNC.m b/screendump/ScreenDumpVNC.m index bce997f..bd2c50e 100644 --- a/screendump/ScreenDumpVNC.m +++ b/screendump/ScreenDumpVNC.m @@ -114,7 +114,7 @@ _staticBuffer = IOSurfaceCreate((CFDictionaryRef) [NSDictionary dictionaryWithObjectsAndKeys: @"PurpleEDRAM", kIOSurfaceMemoryRegion, - [NSNumber numberWithBool:YES], kIOSurfaceIsGlobal, + // [NSNumber numberWithBool:YES], kIOSurfaceIsGlobal, [NSNumber numberWithInt:bytesPerPixel*_width], kIOSurfaceBytesPerRow, [NSNumber numberWithInt:bytesPerPixel], kIOSurfaceBytesPerElement, [NSNumber numberWithInt:_width], kIOSurfaceWidth,