more cleaning

This commit is contained in:
Sam Gateau 2015-02-10 18:41:36 -08:00
parent b9fd116dbf
commit a6f006a36d

View file

@ -686,7 +686,6 @@ bool Model::renderCore(float alpha, RenderMode mode, RenderArgs* args) {
// Let's introduce a gpu::Batch to capture all the calls to the graphics api
_renderBatch.clear();
gpu::Batch& batch = _renderBatch;
//GLBATCH(glPushMatrix)();
// Capture the view matrix once for the rendering of this model
if (_transforms.empty()) {
@ -835,8 +834,6 @@ bool Model::renderCore(float alpha, RenderMode mode, RenderArgs* args) {
GLBATCH(glBindBuffer)(GL_ELEMENT_ARRAY_BUFFER, 0);
GLBATCH(glBindTexture)(GL_TEXTURE_2D, 0);
//GLBATCH(glPopMatrix)();
// Render!
{
PROFILE_RANGE("render Batch");
@ -1649,7 +1646,6 @@ void Model::startScene(RenderArgs::RenderSide renderSide) {
}
void Model::setupBatchTransform(gpu::Batch& batch) {
//GLBATCH(glPushMatrix)();
// Capture the view matrix once for the rendering of this model
if (_transforms.empty()) {
@ -2292,7 +2288,6 @@ int Model::renderMeshesForModelsInScene(gpu::Batch& batch, RenderMode mode, bool
}
model->setupBatchTransform(batch);
meshPartsRendered += model->renderMeshesFromList(list, batch, mode, translucent, alphaThreshold, args, locations, skinLocations);
//GLBATCH(glPopMatrix)();
}
}
}
@ -2392,8 +2387,6 @@ int Model::renderMeshesFromList(QVector<int>& list, gpu::Batch& batch, RenderMod
}
}
// GLBATCH(glPushMatrix)();
const MeshState& state = _meshStates.at(i);
if (state.clusterMatrices.size() > 1) {
GLBATCH(glUniformMatrix4fv)(skinLocations->clusterMatrices, state.clusterMatrices.size(), false,