mirror of https://github.com/encounter/SDL.git
Mac: Fix over-saturated colors on P3 displays (e.g. the 2016 MBPs).
This commit is contained in:
parent
3e9284519a
commit
d719374cb9
|
@ -1276,6 +1276,13 @@ Cocoa_CreateWindow(_THIS, SDL_Window * window)
|
||||||
[nswindow setContentView:contentView];
|
[nswindow setContentView:contentView];
|
||||||
[contentView release];
|
[contentView release];
|
||||||
|
|
||||||
|
/* The app's content is likely authored expecting sRGB output. If we don't
|
||||||
|
* specify the window's color space, it will default to the device color
|
||||||
|
* space, which will be P3 on capable displays. The mismatch causes the
|
||||||
|
* content authored in sRGB to appear extremely saturated on the P3 display.
|
||||||
|
*/
|
||||||
|
[nswindow setColorSpace:[NSColorSpace sRGBColorSpace]];
|
||||||
|
|
||||||
/* Allow files and folders to be dragged onto the window by users */
|
/* Allow files and folders to be dragged onto the window by users */
|
||||||
[nswindow registerForDraggedTypes:[NSArray arrayWithObject:(NSString *)kUTTypeFileURL]];
|
[nswindow registerForDraggedTypes:[NSArray arrayWithObject:(NSString *)kUTTypeFileURL]];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue