Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7108 in orxonox.OLD


Ignore:
Timestamp:
Feb 7, 2006, 11:22:34 PM (14 years ago)
Author:
bensch
Message:

lighting war

Location:
trunk/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/graphics/graphics_engine.cc

    r7035 r7108  
    587587void GraphicsEngine::draw() const
    588588{
    589 
    590   LightManager::getInstance()->draw();
     589//  LightManager::getInstance()->draw();
    591590
    592591  GraphicsEngine::storeMatrices();
  • trunk/src/story_entities/game_world.cc

    r7083 r7108  
    420420  // set camera
    421421  this->dataTank->localCamera->apply ();
     422  this->dataTank->localCamera->project ();
     423  LightManager::getInstance()->draw();
    422424
    423425  /* draw all WorldEntiy groups */
     
    447449  engine->draw();
    448450
     451
    449452  // draw the game ruls
    450453  if( likely(this->dataTank->gameRule != NULL))
  • trunk/src/world_entities/camera.cc

    r7107 r7108  
    178178    // setting up the perspective
    179179  // speed-up feature
     180  glMatrixMode (GL_MODELVIEW);
     181  glLoadIdentity();
     182
     183
     184}
     185
     186void Camera::project()
     187{
    180188  Vector cameraPosition = this->getAbsCoor();
    181189  Vector targetPosition = this->target->getAbsCoor();
    182190
    183   glMatrixMode (GL_MODELVIEW);
    184   glLoadIdentity();
    185 
    186      // Setting the Camera Eye, lookAt and up Vectors
     191       // Setting the Camera Eye, lookAt and up Vectors
    187192  gluLookAt(cameraPosition.x, cameraPosition.y, cameraPosition.z,
    188193            targetPosition.x, targetPosition.y, targetPosition.z,
    189194            this->upVector.x, this->upVector.y, this->upVector.z);
    190 
    191 
    192 }
     195}
     196
    193197
    194198/**
  • trunk/src/world_entities/camera.h

    r7014 r7108  
    5454  void tick(float dt);
    5555  void apply ();
     56  void project();
    5657
    5758  void process(const Event &event);
Note: See TracChangeset for help on using the changeset viewer.