Refactoring
This commit is contained in:
1 parent
7ccda081b0
commit
928600acd4
9 files changed
+46
-213
No files matched your search
@@ -227,11 +227,6 @@ namespace ZL
|
||||
|
||||
renderer.shaderManager.PushShader(defaultShaderName);
|
||||
renderer.RenderUniform1i(textureUniformName, 0);
|
||||
renderer.EnableVertexAttribArray(vPositionName);
|
||||
renderer.EnableVertexAttribArray(vTexCoordName);
|
||||
|
||||
renderer.DisableVertexAttribArray(vPositionName);
|
||||
renderer.DisableVertexAttribArray(vTexCoordName);
|
||||
glEnable(GL_BLEND);
|
||||
menuManager.uiManager.draw(renderer);
|
||||
glDisable(GL_BLEND);
|
||||
@@ -272,16 +267,12 @@ namespace ZL
|
||||
void Game::drawLoading()
|
||||
{
|
||||
static const std::string defaultShaderName = "default";
|
||||
static const std::string vPositionName = "vPosition";
|
||||
static const std::string vTexCoordName = "vTexCoord";
|
||||
static const std::string textureUniformName = "Texture";
|
||||
|
||||
glClear(GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
renderer.shaderManager.PushShader(defaultShaderName);
|
||||
renderer.RenderUniform1i(textureUniformName, 0);
|
||||
renderer.EnableVertexAttribArray(vPositionName);
|
||||
renderer.EnableVertexAttribArray(vTexCoordName);
|
||||
|
||||
//float width = Environment::projectionWidth;
|
||||
//float height = Environment::projectionHeight;
|
||||
@@ -299,9 +290,6 @@ namespace ZL
|
||||
|
||||
renderer.PopMatrix();
|
||||
renderer.PopProjectionMatrix();
|
||||
|
||||
renderer.DisableVertexAttribArray(vPositionName);
|
||||
renderer.DisableVertexAttribArray(vTexCoordName);
|
||||
renderer.shaderManager.PopShader();
|
||||
CheckGlError();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user