diff options
author | Robin Gareus <robin@gareus.org> | 2020-03-24 14:24:14 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2020-03-24 14:24:14 +0100 |
commit | 2f0914c73060bad387bf2d92e5eae2de51b6d1e0 (patch) | |
tree | 92eca6ffd5c1b8f69e29fc5b2450e47c46a8ed4c /libs/gtkmm2ext | |
parent | 0f63b829439e74c9ca8e3e1b8597651ddff361c6 (diff) |
Allow to disable use of NSGLView
On recent Mac systems (Catalina) OpenGL is slower compared to
directly using GTK's NSView. Furthermore when compiled on
Catalina, and running on a system with a Retina screen, the initial
size of the canvas may be wrong:
libs/gtkmm2ext/nsglview.mm:175:1: warning: method possibly
missing a [super reshape] call [-Wobjc-missing-super-calls]
This is not an issue when running versions compiled on older systems.
Diffstat (limited to 'libs/gtkmm2ext')
-rw-r--r-- | libs/gtkmm2ext/nsglview.mm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libs/gtkmm2ext/nsglview.mm b/libs/gtkmm2ext/nsglview.mm index 0eb6a1a5ce..1008f5e602 100644 --- a/libs/gtkmm2ext/nsglview.mm +++ b/libs/gtkmm2ext/nsglview.mm @@ -278,6 +278,9 @@ __attribute__ ((visibility ("hidden"))) void* Gtkmm2ext::nsglview_create (Gtkmm2ext::CairoCanvas* canvas) { + if (g_getenv ("ARDOUR_NSGL") && (0 == atoi (g_getenv ("ARDOUR_NSGL")))) { + return 0; + } /* the API is currently only used on intel mac * for big-endian RGBA <> RGBA byte order of the texture * will have to be swapped. |