Subversion Repositories eduke32

Rev

Rev 8711 | Rev 8713 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 8711 Rev 8712
Line 869... Line 869...
869
    }
869
    }
870
}
870
}
871
871
872
void polymost_activeTexture(GLenum texture)
872
void polymost_activeTexture(GLenum texture)
873
{
873
{
874
    currentActiveTexture = texture;
874
    if (currentActiveTexture != texture)
875
    glad_glActiveTexture(texture);
875
        glad_glActiveTexture(texture);
-
 
876
    currentActiveTexture = texture;
876
}
877
}
877
878
878
//POGOTODO: replace this and polymost_activeTexture with proper draw call organization
879
//POGOTODO: replace this and polymost_activeTexture with proper draw call organization
879
void polymost_bindTexture(GLenum target, uint32_t textureID)
880
void polymost_bindTexture(GLenum target, uint32_t textureID)
880
{
881
{
Line 920... Line 921...
920
    glBindTexture(GL_TEXTURE_2D, pPth->glpic);
921
    glBindTexture(GL_TEXTURE_2D, pPth->glpic);
921
}
922
}
922
923
923
void useShaderProgram(uint32_t shaderID)
924
void useShaderProgram(uint32_t shaderID)
924
{
925
{
-
 
926
    if (currentShaderProgramID != shaderID)
925
    glUseProgram(shaderID);
927
        glUseProgram(shaderID);
926
    currentShaderProgramID = shaderID;
928
    currentShaderProgramID = shaderID;
927
}
929
}
928
930
929
// one-time initialization of OpenGL for polymost
931
// one-time initialization of OpenGL for polymost