From 6b857059516be849e60570445a03f58647656c53 Mon Sep 17 00:00:00 2001 From: Brad Kittenbrink Date: Thu, 23 Jun 2022 17:33:03 -0700 Subject: fixing DRTVWR-559 glext usage on mac by upgrading to use khronos distributed glext.h --- indra/llrender/llglheaders.h | 4 +++- indra/llrender/llglslshader.cpp | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/llrender') diff --git a/indra/llrender/llglheaders.h b/indra/llrender/llglheaders.h index c53631dc7b..154f1aa2bd 100644 --- a/indra/llrender/llglheaders.h +++ b/indra/llrender/llglheaders.h @@ -577,11 +577,13 @@ extern PFNGLUNIFORMBLOCKBINDINGPROC glUniformBlockBinding; //---------------------------------------------------------------------------- // LL_DARWIN +#define GL_GLEXT_LEGACY #include #include #define GL_EXT_separate_specular_color 1 -#include +#define GL_GLEXT_PROTOTYPES +#include "GL/glext.h" #include "GL/glh_extensions.h" diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp index 0212c605c3..67f82c9c5e 100644 --- a/indra/llrender/llglslshader.cpp +++ b/indra/llrender/llglslshader.cpp @@ -452,7 +452,7 @@ BOOL LLGLSLShader::createShader(std::vector * attributes, #ifdef GL_INTERLEAVED_ATTRIBS if (varying_count > 0 && varyings) { - glTransformFeedbackVaryings(mProgramObject, varying_count, varyings, GL_INTERLEAVED_ATTRIBS); + glTransformFeedbackVaryings((GLuint64) mProgramObject, varying_count, varyings, GL_INTERLEAVED_ATTRIBS); } #endif -- cgit v1.2.3 From c13e204474b1f177b696a15348351108c191e429 Mon Sep 17 00:00:00 2001 From: Brad Kittenbrink Date: Thu, 23 Jun 2022 22:32:48 -0700 Subject: WIP adding check for existence of ARB_texture_cube_map_array extension --- indra/llrender/llgl.cpp | 6 ++++++ indra/llrender/llgl.h | 1 + 2 files changed, 7 insertions(+) (limited to 'indra/llrender') diff --git a/indra/llrender/llgl.cpp b/indra/llrender/llgl.cpp index 1a9203ef02..7b1ed62dc9 100644 --- a/indra/llrender/llgl.cpp +++ b/indra/llrender/llgl.cpp @@ -455,6 +455,7 @@ LLGLManager::LLGLManager() : mHasAnisotropic(FALSE), mHasARBEnvCombine(FALSE), mHasCubeMap(FALSE), + mHasCubeMapArray(FALSE), mHasDebugOutput(FALSE), mIsAMD(FALSE), @@ -1069,6 +1070,7 @@ void LLGLManager::initExtensions() mHasDebugOutput = ExtensionExists("GL_ARB_debug_output", gGLHExts.mSysExts); mHasTransformFeedback = mGLVersion >= 4.f ? TRUE : FALSE; mHasUniformBufferObject = ExtensionExists("GL_ARB_uniform_buffer_object", gGLHExts.mSysExts); + mHasCubeMapArray = ExtensionExists("GL_ARB_texture_cube_map_array", gGLHExts.mSysExts); #if !LL_DARWIN mHasPointParameters = ExtensionExists("GL_ARB_point_parameters", gGLHExts.mSysExts); #endif @@ -1181,6 +1183,10 @@ void LLGLManager::initExtensions() { LL_INFOS("RenderInit") << "Couldn't initialize GL_ARB_draw_buffers" << LL_ENDL; } + if (!mHasCubeMapArray) + { + LL_INFOS("RenderInit") << "Couldn't initialize GL_ARB_texture_cube_map_array" << LL_ENDL; + } // Disable certain things due to known bugs if (mIsIntel && mHasMipMapGeneration) diff --git a/indra/llrender/llgl.h b/indra/llrender/llgl.h index eea53ed01e..cd0b247ed8 100644 --- a/indra/llrender/llgl.h +++ b/indra/llrender/llgl.h @@ -114,6 +114,7 @@ public: BOOL mHasAnisotropic; BOOL mHasARBEnvCombine; BOOL mHasCubeMap; + BOOL mHasCubeMapArray; BOOL mHasDebugOutput; BOOL mHassRGBTexture; BOOL mHassRGBFramebuffer; -- cgit v1.2.3