#else
drivername = "libGL.so.1";
#endif
+
+#ifndef ANTICHEAT
// COMMANDLINEOPTION: Linux GLX: -gl_driver <drivername> selects a GL driver library, default is libGL.so.1, useful only for using fxmesa or similar, if you don't know what this is for, you don't need it
// COMMANDLINEOPTION: BSD GLX: -gl_driver <drivername> selects a GL driver library, default is libGL.so.1, useful only for using fxmesa or similar, if you don't know what this is for, you don't need it
// LordHavoc: although this works on MacOSX, it's useless there (as there is only one system libGL)
i = COM_CheckParm("-gl_driver");
if (i && i < com_argc - 1)
drivername = com_argv[i + 1];
+#endif
if (!GL_OpenLibrary(drivername))
{
Con_Printf("Unable to load GL driver \"%s\"\n", drivername);
// SDL usually knows best
drivername = NULL;
+#ifndef ANTICHEAT
// COMMANDLINEOPTION: SDL GL: -gl_driver <drivername> selects a GL driver library, default is whatever SDL recommends, useful only for 3dfxogl.dll/3dfxvgl.dll or fxmesa or similar, if you don't know what this is for, you don't need it
i = COM_CheckParm("-gl_driver");
if (i && i < com_argc - 1)
drivername = com_argv[i + 1];
+#endif
+
if (SDL_GL_LoadLibrary(drivername) < 0)
{
Con_Printf("Unable to load GL driver \"%s\": %s\n", drivername, SDL_GetError());
*af = 0;
gldrivername = "opengl32.dll";
+
+#ifndef ANTICHEAT
// COMMANDLINEOPTION: Windows WGL: -gl_driver <drivername> selects a GL driver library, default is opengl32.dll, useful only for 3dfxogl.dll or 3dfxvgl.dll, if you don't know what this is for, you don't need it
i = COM_CheckParm("-gl_driver");
if (i && i < com_argc - 1)
gldrivername = com_argv[i + 1];
+#endif
+
if (!GL_OpenLibrary(gldrivername))
{
Con_Printf("Unable to load GL driver %s\n", gldrivername);