-
-
Notifications
You must be signed in to change notification settings - Fork 532
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
macOS Catalina: Only bottom left quarter of the screen is used by the game #422
Comments
I would assume you’ve tried doubling (or whatever it takes to get to desktop retina) the custom resolution |
I have the same issue on mbp 2017 |
Add this to the bottom of ioquake3.app/Contents/Info.plist, right above the "" line:
You might have to copy (not move) the app to a different name to get Launch Services to notice the change, and then nuke the original and copy it back. This might be optional. This fixes the problem. I assume for things built with Xcode 11 on Catalina, NSHighResolutionCapable now defaults to true, when it hasn't before. What this flag does is say "my app wants all available pixels at full resolution, not the virtual pixels of what my desktop is scaled to." The end result is we ask for a fullscreen 800x600 window (or whatever), but are ending up with 1600x1200 pixels (or whatever) in the GL context. Then the glViewport(0,0,800,600) call makes it use a quarter of the available space. Longer term, we can fix this in ioquake3 by setting glViewport to the sizes reported by SDL_GL_GetDrawableSize(), which tells you the size of the window in retina pixels instead of the scaled pixel count that we use for creating the window, but there's a lot of code to sort through that assumes these two pixel counts match 1:1. Longer longer term: we should render to an FBO at exactly the size we want, use SDL_WINDOW_FULLSCREEN_DESKTOP, and framebuffer_blit to scale/letterbox the final result on the actual window framebuffer. --ryan. |
Hi, my experience is slightly different: macOS 10.14: Ok I've changed the resolution to 1440×900 as a workaround, works fine. |
@rcgordon yup, that fixes it. In the other games I mentioned too. I'll try to the build scripts this evening. |
@rcgordon I integrate your solution to my ioquake-mac-install repository, a repository that pretends be an unified simply way to install ioquake3 on macOS (catalina compatible). I'm working on it and it couldn't be possible without you. Thanks for all! |
I don't mind. |
Some info from the same issue in the Godot engine. You can disable HiDPI support from the code by calling |
Looks like it is fixed for SDL 2.0.12 using the same method as Godot engine. https://hg.libsdl.org/SDL/rev/46b094f7d20e |
When we move to SDL 2.0.12 (still in progress!) then we should definitely remove this from the Info.plist, as we'll want to eventually handle this better in the ioQuake3 codebase itself, too, and that'll cause issues, but I think that should be a different bug report at a later time. For now, the Info.plist change is the correct immediate solution. |
I'm also seeing this on Debian Buster (Lenovo X1 Carbon with Intel graphics.) I presume the "longer term" and "longer longer term" changes mentioned in #422 (comment) will apply to Linux as well, but in the interim, there seems to be no workaround. I'm fine running in a window for now, but with the poor performance of Intel graphics, running at a lower resolution scaled up to fullscreen would be preferred. Meta comment: should I open a separate issue for Linux specifically, or can that be tracked here as well? |
@mhoran Quake3e has // Use 4 instead of 2 for linear filtering (blurrier).
r_renderScale 2
r_renderwidth 1280
r_renderHeight 720
vid_restart Note: This breaks if antialiasing is forced in the NVIDIA control panel. (This note is only relevant for NVIDIA graphics anyway.) |
Thanks for the heads up, @Calinou. I may check that port out. After further investigation I believe I may be hitting a separate issue that is likely Linux specific. It seems to have something to do with multi-head. I'll do some more digging and potentially open another issue. |
Quake3e doesn't support Mac and is unlikely to without a Mac developer |
I'm having the same issue described by @dmitrydyomin, the NSHighResolutionCapable fix didn't work for me. Is there something else I could try? |
I had this problem with a GLUT task (old GLUT, not freeglut) run from a terminal. This has no obvious way of setting NSHighResolutionCapable. However, I managed to fix this by calling the glut reshape function just after glutShowWindow(). It also has to actually reshape the window - if it is already that size it won't work. The text comes out half sized, but double spaced. I will post again if I can figure that out. |
Here's the other half of my fix. Background: I have a GLUT job that I run from a terminal. I have used and fiddled with for the last 20 years. For various reasons I am stuck with the original GLUT. This stopped looking right with Catalina. I have not got a practical way to set NSHighResolutionCapable. In the last post I had to force an actual image resize to stop the drawing in the bottom left quadrant. The text now was coming out looking small, but with the right line spacing so...
On my machine, if you set the cursor position as 16,16, glGetIntegerv gets back 32,32. Here DARWIN is a compiler flag which is set if I am compiling on a Mac, so you will need your own flag for that. Here I use a bigger font (not much) and a bigger line spacing when you correct for the scaling. I am working at home, so I have tried this on the one machine only. I think it has to work for every if the old GLUTworks at all but YMMV. Please post if you find problems. |
When running ioquake3 on macOS 10.15 Catalina, after having compiled from the latest source on the command line via Makefile, the resulting window only features the game in the lower left quadrant of the screen and the other 3/4 of the screen is black.
This is launching with just the most standard, vanilla, baseq3 available. No mods, just double-clicking on ioquake3.app under the resulting release-darwin-x86_64.
It's also happening in a build I did of yquake2, as well as another, non-SDL port of Quake II, so I don't think it's related to SDL but it may be related to either OpenGL or just how graphics in general work now but in any event it's not just ioquake3 alone.
I'm using a MacBook Pro Retina, mid-2014 model, with an Nvidia GeForce GT 750M.
The craziest part though is a version of ioquake3 I built before the Catalina upgrade works fine. So it's as if the 10.15 version of the macOS SDK has something to do with it.
Were I to guess I'd say it has something to do with the Retina display and maybe a change in how Catalina calculates screen sizes or something but I've not had luck figuring out what/where that is.
I do plan on digging in to it and seeing if I can figure it out but I thought I'd open an issue just in case someone sees it and can figure it out quicker than I can.
The text was updated successfully, but these errors were encountered: