1.11.6 not working on OSX

Problems building or running the engine, queries about how to use features etc.
Post Reply
glennr
Greenskin
Posts: 112
Joined: Thu Jun 05, 2008 3:26 am
Location: Thames, New Zealand
x 3

1.11.6 not working on OSX

Post by glennr » Thu Apr 18, 2019 1:51 am

Ogre Version: :1.11.6 stable from git:
Operating System: :OSX 10.14.4:
Render System: :OpenGL and GL3+:

I have an app with Windows and OSX versions that uses Ogre embedded in Qt, up to version 1.10 it's worked properly on both platforms. I've just ported it to use RTSS and it works on Windows as expected with D3D9, OpenGL, D3D11 and GL3+.
On OSX the graphics loop runs but I don't see anything on the screen. I also notice that the SampleBrowser app doesn't run on OSX and appears to have a similar issue where the graphics loop runs but the window doesn't show. I've reported this here: https://github.com/OGRECave/ogre/issues/1170 . (The build system doesn't appear to deploy libfreetype.x.y.dylib to the right place so I copied that manually to get it to run at all.)

I'm wondering if anyone else is successfully running 1.11 on OSX 10.14? If so, any tips?
0 x

User avatar
EricB
Gnome
Posts: 314
Joined: Fri Apr 09, 2010 5:28 am
Location: Florida
x 103
Contact:

Re: 1.11.6 not working on OSX

Post by EricB » Fri Apr 19, 2019 1:26 am

1.11.5 is working fine for me and a few hundred users on all versions of OSX after 10.10. (I didn't know there was a 1.11.6 branch.)

OpenGL2, GWFL for windowing. RTSS currently disabled, but I just recently re-enabled it and will be testing it on the platform in a couple of days.
0 x
Image

glennr
Greenskin
Posts: 112
Joined: Thu Jun 05, 2008 3:26 am
Location: Thames, New Zealand
x 3

Re: 1.11.6 not working on OSX

Post by glennr » Tue Apr 23, 2019 12:05 am

Thanks for that. With SDL installed the SampleBrowser app works.

However according to paroj:
ogre falls back to creating the window internally if SDL is not available. Apparently this path is broken as well.
0 x

User avatar
EricB
Gnome
Posts: 314
Joined: Fri Apr 09, 2010 5:28 am
Location: Florida
x 103
Contact:

Re: 1.11.6 not working on OSX

Post by EricB » Wed Apr 24, 2019 3:57 am

Ogre does work without using SDL or GLFW (in my case) for window management, however you will have to do quite a bit of Object-C. You'll also run into about a thousand little stupid issues that comes with Mac programming. So it's better to use SDL or GLFW, which you already have! Good luck!
0 x
Image

glennr
Greenskin
Posts: 112
Joined: Thu Jun 05, 2008 3:26 am
Location: Thames, New Zealand
x 3

Re: 1.11.6 not working on OSX

Post by glennr » Tue Apr 30, 2019 10:22 pm

There seem to be conflicting answers here.

Can I expect the SampleBrowser to work on OSX straight out of the box if I don't have SDL installed?
0 x

glennr
Greenskin
Posts: 112
Joined: Thu Jun 05, 2008 3:26 am
Location: Thames, New Zealand
x 3

Re: 1.11.6 not working on OSX

Post by glennr » Tue Apr 30, 2019 10:30 pm

Some further information on my app's behaviour.

If I have an external monitor attached and also open the laptop so I have an the 2 displays side by side then on starting my app, it appears on the external monitor and the 3D graphics are not visible but if I drag the my app's window to the laptop monitor then as soon as the mouse pointer changes to the other screen the 3D graphics appear and remain visible thereafter, wherever the window is positioned. When running the app with only one display, either external or laptop, the ogre graphics never appear.

This is with 1.11, it works as expected with 1.10.

This OSX machine is a mid 2012 macbook pro. It has 2 GPUs - NVIDIA GeForce GT 650M and Intel HD Graphics 4000.
0 x

User avatar
EricB
Gnome
Posts: 314
Joined: Fri Apr 09, 2010 5:28 am
Location: Florida
x 103
Contact:

Re: 1.11.6 not working on OSX

Post by EricB » Wed May 01, 2019 5:35 am

glennr wrote:
Tue Apr 30, 2019 10:22 pm
There seem to be conflicting answers here.

Can I expect the SampleBrowser to work on OSX straight out of the box if I don't have SDL installed?
SampleBrowsers? No, you have to use whatever code/libraries Paroj uses for the samples.

I was speaking in general.
0 x
Image

paroj
OGRE Team Member
OGRE Team Member
Posts: 774
Joined: Sun Mar 30, 2014 2:51 pm
x 119
Contact:

Re: 1.11.6 not working on OSX

Post by paroj » Wed May 01, 2019 12:42 pm

glennr wrote:
Tue Apr 30, 2019 10:30 pm
Some further information on my app's behaviour.

If I have an external monitor attached and also open the laptop so I have an the 2 displays side by side then on starting my app, it appears on the external monitor and the 3D graphics are not visible but if I drag the my app's window to the laptop monitor then as soon as the mouse pointer changes to the other screen the 3D graphics appear and remain visible thereafter, wherever the window is positioned. When running the app with only one display, either external or laptop, the ogre graphics never appear.

This is with 1.11, it works as expected with 1.10.

This OSX machine is a mid 2012 macbook pro. It has 2 GPUs - NVIDIA GeForce GT 650M and Intel HD Graphics 4000.
This sounds like we are not calling some method any more that is implicitly called when you move the window across screens. Actually a lot of stuff happens behind the scenes if the screens are handled by different GPUs. See https://en.wikipedia.org/wiki/Nvidia_Optimus

A notable change between 1.10 and 1.11 is this:
https://github.com/OGRECave/ogre/blob/m ... t-ogremain

you might want to compare the GLSupport component between 1.10 and 1.11 and look for suspicious changes. Also the functionality of the ApplicationContext class was reduced when SDL2 is not available, as we do not want to re-implement SDL2 in ogre.
0 x

glennr
Greenskin
Posts: 112
Joined: Thu Jun 05, 2008 3:26 am
Location: Thames, New Zealand
x 3

Re: 1.11.6 not working on OSX

Post by glennr » Thu May 02, 2019 1:30 am

The 1.10 OSX there is some cocoa window event handling code in ogre-1-10\RenderSystems\GLSupport\src\OSX\OgreOSXCocoaWindowDelegate.mm which gets instantiated in ogre-1-10\RenderSystems\GLSupport\src\OSX\OgreOSXCocoaWindow.mm .

In 1.11, the platform specific stuff was moved to OgreBites and I can see that there is window event handling code for Windows and Linux/X11 in ogre-1-11\Components\Bites\src\OgreWindowEventUtilities.cpp but there is no corresponding code for OSX.

OgreOSXCocoaWindowDelegate.mm appears to have completely disappeared from 1.11. Should it have been moved to OgreBites too?
0 x

Post Reply