| Summary: | NSRequiresAquaSystemAppearance makes some applications blurry on macOS Retina display | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Donovan Watteau <contrib> |
| Component: | render | Assignee: | Alex Szpakowski <amaranth72> |
| Status: | ASSIGNED --- | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | 2.0.12 | ||
| Hardware: | x86_64 | ||
| OS: | macOS 10.14 | ||
| Attachments: | Sharp text on the left (ScummVM 2.1.0-beta), blurrier text on the right (ScummVM 2.1.2 exploiting Dark mode with NSRequiresAquaSystemAppearance) | ||
|
Description
Donovan Watteau
2020-04-13 15:55:23 UTC
Alex, any ideas on this? I'm guessing VMWare removed the NSRequiresAquaSystemAppearance key and built using the 10.14+ SDK instead. ScummVM should probably do the same, I guess. Upstream likes to provide a good amount of backward compatibility for older macOS releases, so I'm not sure they will chose to use the 10.14+ SDK. Maybe this will be worked around by removing NSRequiresAquaSystemAppearance and missing Dark mode for now, instead. Anyway, I see that a similar Radar was reported to Apple, back in early Mojave betas: https://openradar.appspot.com/45895864 And it looks like VLC was hit by a similar problems, but they had another way of working around it, it seems: https://code.videolan.org/videolan/VLCKit/issues/82#note_30971 I don't know if this can be worked around in SDL2 code as well, or if I should try to open a new Radar (I doubt Apple will care), or if NSRequiresAquaSystemAppearance should be documented as buggy. (In reply to Donovan Watteau from comment #3) > Upstream likes to provide a good amount of backward compatibility for older > macOS releases, so I'm not sure they will chose to use the 10.14+ SDK. > Maybe this will be worked around by removing NSRequiresAquaSystemAppearance > and missing Dark mode for now, instead. Compiling with a newer SDK doesn't prevent an app from running on older operating systems - there's a separate minimum OS target setting from the current SDK being used, so for example I compile my apps with the 10.15 SDK and set their minimum deployment target to 10.7, and they'll run on every OS version between 10.7 and 10.15 (and on newer operating systems when they're released - just not with every new feature of that new OS version). The layer backed NSOpenGLView stuff is pretty fragile so I'm not sure I'd recommend changing how that works for an issue like this, but maybe someone could find a robust workaround there with some time invested. To me it feels like a much less ideal solution than just using a newer SDK though. (In reply to Alex Szpakowski from comment #4) > (In reply to Donovan Watteau from comment #3) > > Upstream likes to provide a good amount of backward compatibility for older > > macOS releases, so I'm not sure they will chose to use the 10.14+ SDK. > > Maybe this will be worked around by removing NSRequiresAquaSystemAppearance > > and missing Dark mode for now, instead. > > Compiling with a newer SDK doesn't prevent an app from running on older > operating systems - there's a separate minimum OS target setting from the > current SDK being used, so for example I compile my apps with the 10.15 SDK > and set their minimum deployment target to 10.7, and they'll run on every OS > version between 10.7 and 10.15 (and on newer operating systems when they're > released - just not with every new feature of that new OS version). > > The layer backed NSOpenGLView stuff is pretty fragile so I'm not sure I'd > recommend changing how that works for an issue like this, but maybe someone > could find a robust workaround there with some time invested. To me it feels > like a much less ideal solution than just using a newer SDK though. Yes, sorry, I forgot that. Unfortunately, after removing any NSRequiresAquaSystemAppearance mention, and building ScummVM 2.2.0git with the 10.14 SDK and targeting either a 10.9 or 10.14 compatibility (the instructions about building it with Xcode are on their Wiki), the app still remains blurry by default on Mojave. So it looks like the only workaround is to build with a pre-10.14 SDK, and NOT to use NSRequiresAquaSystemAppearance. Otherwise, you get the blurring issues. So this macOS bug looks more problematic. (I wish I could provide you a simpler use case to reproduce this on 10.14+, but I'm just a ScummVM user, and finding the smallest snippet of code reproducing this issue is above my SDL programming knowledge...) Hi, To keep you informed: criezy from the ScummVM team found that you can also work around the blurring issue on 10.14+ SDKs by building with a SDK value set to n/a: https://bugs.scummvm.org/ticket/11430 This comes from LibreOffice, which had a similar issue: https://bugs.documentfoundation.org/show_bug.cgi?id=122218 I've reported the bug to Apple, but I'm not sure they're going to do something about this. I don't know if something can be worked around by default in SDL2 in itself, but hopefully this bug report might help documenting this macOS bug. |