Page 1 of 1

Invisible cursor when compiled from source (macOS)

Posted: 16 Dec 2017, 14:15
by dedaenc
Hi everyone,

I'm having an issue where the cursor is invisible on menu screens. This happens on clean builds, with no mods, when compiled from scratch using the GitHub repo. The action of the cursor is present, but it's impossible to track its position. Occasionally the cursor symbol is replaced by an inconsistent glitchy box.

The cursor works fine using the pre-compiled 0.43 macOS binary, but I like to use Scrawl's first-person-enhanced-style patch (https://bugs.openmw.org/issues/2666#change-14749) when I play (and I just get a kick out of tracking the progress in the master). This issue is present without the patch using the master branch though.

I use the CI scripts to set up the build, though as I'm using macOS 10.13, I change the CMAKE_OSX_DEPLOYMENT_TARGET (nothing else). I believe this issue only started when I upgraded to 10.13, but I can't be sure. I get the same issue when I compile and use openmw-deps-mac to build the dependencies; everything works perfectly, except the cursor.

It's a small issue, but I'd love a fix. Does anyone know what might be causing this?

Many thanks in advance,
Dedaenc

Re: Invisible cursor when compiled from source (macOS)

Posted: 06 May 2018, 21:14
by corristo
I've run into the same issue after bumping macOS SDK version & dependency versions.

Nothing suspicious in the openmw output/log. I'd appreciate any help.

UPD after rereading the original post: it seems like the base SDK of the app itself might cause this. I suspect that setting base SDK to 10.13 changes some code paths in OpenGL implementation/driver, thus causing this. And no, it doesn't seem to have anything to do with the upside down cursor workaround, I already tried disabling it.

UPD2: I confused "base SDK" and "deployment target", although setting deployment target to 10.13 as in the original post would obviously require setting base SDK to 10.13 too.

Re: Invisible cursor when compiled from source (macOS)

Posted: 16 May 2018, 22:13
by tobin
Oh wow I totally missed this thread. Yeah I ran into the same thing and only resolved it by building on the SDK for 10.12.

Re: Invisible cursor when compiled from source (macOS)

Posted: 20 May 2018, 18:04
by corristo
I debugged a bit and looks like glReadPixels is failing with GL_INVALID_FRAMEBUFFER_OPERATION.

Re: Invisible cursor when compiled from source (macOS)

Posted: 20 May 2018, 19:33
by corristo
To be precise, the error is occurring in these part of the code: https://github.com/OpenMW/osg/blob/2b4c ... #L745-L755.
"Warning: detected OpenGL error 'invalid framebuffer operation' at end of Geometry::drawImplementation()." gets printed.

Re: Invisible cursor when compiled from source (macOS)

Posted: 24 May 2018, 21:10
by corristo

Re: Invisible cursor when compiled from source (macOS)

Posted: 27 May 2018, 14:52
by corristo
https://bugs.openmw.org/issues/4424#note-7

TL;DR the method that OSG uses to create pbuffers on macOS is deprecated since macOS 10.7, no wonder it's no longer working in 10.13.

Re: Invisible cursor when compiled from source (macOS)

Posted: 09 Jun 2018, 12:03
by corristo
I'm happy to let you know that I have a working fix: viewtopic.php?f=6&t=5202.

Re: Invisible cursor when compiled from source (macOS)

Posted: 22 Jun 2018, 09:17
by corristo
It's no longer an issue in openmw-44 and master branches.