Remove Tegra support hacks

Signed-off-by: renderexpert <expert@renderconsulting.co.uk>
This commit is contained in:
renderexpert
2025-01-24 14:30:29 +00:00
committed by Konstantin Pastbin
parent a406462549
commit 9b3507211f
3 changed files with 2 additions and 20 deletions

View File

@@ -23,26 +23,14 @@ GLGpuProgram::GLGpuProgram(std::string const & programName,
if (!GLFunctions::glLinkProgram(m_programID, errorLog))
LOG(LERROR, ("Program ", programName, " link error = ", errorLog));
// On Tegra3 glGetActiveUniform isn't work if you detach shaders after linking.
LoadUniformLocations();
// On Tegra2 we cannot detach shaders at all.
// https://devtalk.nvidia.com/default/topic/528941/alpha-blending-not-working-on-t20-and-t30-under-ice-cream-sandwich/
if (!SupportManager::Instance().IsTegraDevice())
{
GLFunctions::glDetachShader(m_programID, m_vertexShader->GetID());
GLFunctions::glDetachShader(m_programID, m_fragmentShader->GetID());
}
GLFunctions::glDetachShader(m_programID, m_vertexShader->GetID());
GLFunctions::glDetachShader(m_programID, m_fragmentShader->GetID());
}
GLGpuProgram::~GLGpuProgram()
{
if (SupportManager::Instance().IsTegraDevice())
{
GLFunctions::glDetachShader(m_programID, m_vertexShader->GetID());
GLFunctions::glDetachShader(m_programID, m_fragmentShader->GetID());
}
GLFunctions::glDeleteProgram(m_programID);
}