factor icon indicating copy to clipboard operation
factor copied to clipboard

macOS should use OpenGL 3 or 4 instead of 2.1

Open erg opened this issue 8 years ago • 5 comments

We want to use core mode, not compatibility mode, but this deprecates some features like immediate mode (glBegin, glEnd). The way to initialize it is supposedly something like the following patch, but I can't get it to work yet. Also, we will have to take care to not use any other deprecated OpenGL functions.

 : pixel-format-attributes>int-array ( attrs perm table -- arr )
     swapd '[ _ at ] map sift concat append
     ! 0 happens to work as a sentinel value for all ui backends.
+    ! NSOpenGLPFAOpenGLProfile NSOpenGLProfileVersion3_2Core 2array prepend

erg avatar May 31 '17 18:05 erg

You should probably put that code in M\ cocoa-ui-backend (make-pixel-format).

mrjbq7 avatar May 31 '17 23:05 mrjbq7

Related to #1868

erg avatar Nov 11 '17 17:11 erg

But if we do that, don't we have to drop support for older OSes which do not have recent versions of opengl?

bjourne avatar Jan 19 '18 21:01 bjourne

https://developer.apple.com/opengl/OpenGL-Capabilities-Tables.pdf

erg avatar Dec 02 '18 15:12 erg

Windows still only comes with an OpenGL 1.1 implementation unless your graphics driver provides an ICD. You all might want to look into using ANGLE or some other portable OpenGL implementation that sits on top of the native graphics APIs on each platform.

jckarter avatar Dec 02 '18 17:12 jckarter