mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-12-19 13:37:00 +00:00
only use GL_COMPLETION_STATUS_ARB when the extension is used
This commit is contained in:
parent
328509e719
commit
7a4c539a00
1 changed files with 9 additions and 2 deletions
|
|
@ -146,7 +146,14 @@ bool RendererShaderGL::IsCompiled()
|
||||||
{
|
{
|
||||||
if(m_isCompiled)
|
if(m_isCompiled)
|
||||||
return true;
|
return true;
|
||||||
GLint isShaderComplete;
|
|
||||||
|
if(!glMaxShaderCompilerThreadsARB)
|
||||||
|
{
|
||||||
|
WaitForCompiled();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
GLint isShaderComplete = 0;
|
||||||
glGetShaderiv(m_shader_object, GL_COMPLETION_STATUS_ARB, &isShaderComplete);
|
glGetShaderiv(m_shader_object, GL_COMPLETION_STATUS_ARB, &isShaderComplete);
|
||||||
if (isShaderComplete)
|
if (isShaderComplete)
|
||||||
WaitForCompiled(); // since COMPLETION_STATUS == true, this should be very fast
|
WaitForCompiled(); // since COMPLETION_STATUS == true, this should be very fast
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue