1.11.6 not working on OSX
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
1.11.6 not working on OSX
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?
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?
- EricB
- Bronze Sponsor
- Posts: 360
- Joined: Fri Apr 09, 2010 5:28 am
- Location: Florida
- x 213
- Contact:
Re: 1.11.6 not working on OSX
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.
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.
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
Thanks for that. With SDL installed the SampleBrowser app works.
However according to paroj:
However according to paroj:
ogre falls back to creating the window internally if SDL is not available. Apparently this path is broken as well.
- EricB
- Bronze Sponsor
- Posts: 360
- Joined: Fri Apr 09, 2010 5:28 am
- Location: Florida
- x 213
- Contact:
Re: 1.11.6 not working on OSX
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!
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
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?
Can I expect the SampleBrowser to work on OSX straight out of the box if I don't have SDL installed?
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
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.
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.
- EricB
- Bronze Sponsor
- Posts: 360
- Joined: Fri Apr 09, 2010 5:28 am
- Location: Florida
- x 213
- Contact:
Re: 1.11.6 not working on OSX
SampleBrowsers? No, you have to use whatever code/libraries Paroj uses for the samples.
I was speaking in general.
-
- OGRE Team Member
- Posts: 1995
- Joined: Sun Mar 30, 2014 2:51 pm
- x 1075
- Contact:
Re: 1.11.6 not working on OSX
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_Optimusglennr 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.
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.
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
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?
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?
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
Any thoughts about the missing OgreOSXCocoa*.mm files?
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
Not working in 1.12.1 either.
Can someone help me out with the missing OSX code? Was it mistakenly or intentionally removed?
Can someone help me out with the missing OSX code? Was it mistakenly or intentionally removed?
-
- OGRE Team Member
- Posts: 1995
- Joined: Sun Mar 30, 2014 2:51 pm
- x 1075
- Contact:
Re: 1.11.6 not working on OSX
Try adding the Code Back in 1.12 or 1.11 and verify whether it solves your Problem.
The Code was probably removed in assumption of sdl2 being used.
The Code was probably removed in assumption of sdl2 being used.
-
- Greenskin
- Posts: 126
- Joined: Thu Jun 05, 2008 3:26 am
- Location: Thames, New Zealand
- x 9
Re: 1.11.6 not working on OSX
Adding the code back didn't make any difference.
However I have now tried it using 1.10.12 and it has the same issue. That points to the problem being in the macOS SDK or Xcode.
When building on OSX 10.14.5 I'm using Xcode 10.2.1, but on 10.11.6, where the built program doesn't have this issue, I'm building using Xcode 8.2.1. So some version of Xcode between those two broke it. I suspect is was 10.