Subversion Repository Public Repository

Divide-Framework

This repository has no backups
This repository's network speed is throttled to 100KB/sec

Diff Revisions 167 vs 168 for /trunk/Source Code/Rendering/RenderPass/RenderBin.cpp

Diff revisions: vs.
  @@ -148,14 +148,16 @@
148 148 LightManager& lightMgr = LightManager::getInstance();
149 149 //if needed, add more stages to which lighting is applied
150 150 U32 lightValidStages = DISPLAY_STAGE | REFLECTION_STAGE;
151 -
152 151 bool isDepthPass = bitCompare(DEPTH_STAGE, currentRenderStage);
153 152 bool isLightValidStage = bitCompare(lightValidStages, currentRenderStage);
153 +
154 154 for(U16 j = 0; j < getBinSize(); j++){
155 155 //Get the current scene node and validate it
156 - sgn = getItem(j)._node; assert(sgn);
156 + sgn = getItem(j)._node;
157 + assert(sgn);
157 158 //And get it's attached SceneNode and validate it
158 - sn = sgn->getNode<SceneNode>(); assert(sn);
159 + sn = sgn->getNode<SceneNode>();
160 + assert(sn);
159 161
160 162 //Call any pre-draw operations on the SceneNode (refresh VBO, update materials, etc)
161 163 sn->onDraw(currentRenderStage);
  @@ -173,7 +175,7 @@
173 175 //Only 2 sets of shadow maps for every node
174 176 }
175 177
176 - CLAMP<U8>(lightCount, 0, MAX_SHADOW_CASTING_LIGHTS_PER_NODE);
178 + CLAMP<U8>(lightCount, 0, Config::MAX_SHADOW_CASTING_LIGHTS_PER_NODE);
177 179 //Apply shadows only from the most important MAX_SHADOW_CASTING_LIGHTS_PER_NODE lights
178 180 if(isLightValidStage){
179 181 U8 offset = 9;
  @@ -187,6 +189,7 @@
187 189 //As nodes are sorted, this should be very fast
188 190 //We need to apply different materials for each stage
189 191 isDepthPass ? sn->prepareDepthMaterial(sgn) : sn->prepareMaterial(sgn);
192 +
190 193 //Call render and the stage exclusion mask should do the rest
191 194 sn->render(sgn);
192 195