Ticket #847: t847_osx-getvideomode-v1.patch
File t847_osx-getvideomode-v1.patch, 821 bytes (added by , 12 years ago) |
---|
-
source/lib/sysdep/os/osx/osx.cpp
61 61 62 62 Status GetVideoMode(int* xres, int* yres, int* bpp, int* freq) 63 63 { 64 // TODO Implement 65 return ERR::NOT_SUPPORTED; // NOWARN 64 // CGDisplayModeRef currentMode = CGDisplayCopyDisplayMode(kCGDirectMainDisplay); 65 66 if(xres) 67 *xres = (int)CGDisplayPixelsWide(kCGDirectMainDisplay); 68 if(yres) 69 *yres = (int)CGDisplayPixelsHigh(kCGDirectMainDisplay); 70 if(bpp) 71 *bpp = (int)CGDisplayBitsPerPixel(kCGDirectMainDisplay); 72 if(freq) 73 *freq = (int)CGDisplayModeGetRefreshRate(currentMode); 74 75 return INFO::OK; 66 76 } 67 77 68 78 Status GetMonitorSize(int* xres, int* yres, int* bpp, int* freq)