소스 검색

Removed the duplicate FrameInfo structure for shadow rendering as unnecessary.

Lasse Öörni 14 년 전
부모
커밋
62e5541039
2개의 변경된 파일1개의 추가작업 그리고 6개의 파일을 삭제
  1. 1 4
      Engine/Graphics/View.cpp
  2. 0 2
      Engine/Graphics/View.h

+ 1 - 4
Engine/Graphics/View.cpp

@@ -139,8 +139,6 @@ void View::Update(const FrameInfo& frame)
     frame_.frameNumber_ = frame.frameNumber_;
     frame_.viewSize_ = IntVector2(width_, height_);
     
-    shadowFrame_ = frame_;
-    
     // Clear old light scissor cache, geometry, light, occluder & batch lists
     lightScissorCache_.Clear();
     geometries_.Clear();
@@ -435,7 +433,6 @@ void View::GetBatches()
                 shadowQueue.shadowCamera_ = shadowCameras_[j];
                 shadowQueue.nearSplit_ = shadowNearSplits_[j];
                 shadowQueue.farSplit_ = shadowFarSplits_[j];
-                shadowFrame_.camera_ = shadowCamera;
                 
                 // Setup the shadow split viewport and finalize shadow camera parameters
                 shadowQueue.shadowViewport_ = GetShadowMapViewport(light, j, lightQueue.shadowMap_);
@@ -450,7 +447,7 @@ void View::GetBatches()
                     for (unsigned l = 0; l < numBatches; ++l)
                     {
                         Batch shadowBatch;
-                        drawable->GetBatch(shadowBatch, shadowFrame_, l);
+                        drawable->GetBatch(shadowBatch, frame_, l);
                         
                         Technique* tech = GetTechnique(drawable, shadowBatch.material_);
                         if (!shadowBatch.geometry_ || !tech)

+ 0 - 2
Engine/Graphics/View.h

@@ -178,8 +178,6 @@ private:
     int maxOccluderTriangles_;
     /// Information of the frame being rendered.
     FrameInfo frame_;
-    /// Information of the frame being rendered, with shadow camera.
-    FrameInfo shadowFrame_;
     /// Camera frustum.
     Frustum frustum_;
     /// Combined bounding box of visible geometries.