Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4832 in orxonox.OLD for orxonox/trunk/src/world_entities/camera.cc


Ignore:
Timestamp:
Jul 11, 2005, 5:45:27 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: loadParams and timing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/world_entities/camera.cc

    r4746 r4832  
    11
    22
    3 /* 
     3/*
    44   orxonox - the future of 3D-vertical-scrollers
    55
     
    127127      this->toRelCoor = Vector(12, 5, 0);
    128128      break;
    129     case VIEW_LEFT: 
     129    case VIEW_LEFT:
    130130      this->toFovy = 90;
    131131      this->toRelCoor = Vector(0, 2, -10);
     
    148148void Camera::tick(float dt)
    149149{
    150   dt /= 500;
    151150  float tmpFovy = (this->toFovy - this->fovy) * dt;
    152151  if (tmpFovy > .001)
     
    163162/**
    164163   \brief initialize rendering perspective according to this camera
    165    
     164
    166165   This is called immediately before the rendering cycle starts, it sets all global
    167166   rendering options as well as the GL_PROJECTION matrix according to the camera.
     
    175174  // setting up the perspective
    176175  gluPerspective(this->fovy,
    177                 this->aspectRatio,
    178                 this->nearClip,
    179                 this->farClip);
     176                this->aspectRatio,
     177                this->nearClip,
     178                this->farClip);
    180179
    181180  // speed-up feature
     
    187186  // Setting the Camera Eye, lookAt and up Vectors
    188187  gluLookAt(cameraPosition.x, cameraPosition.y, cameraPosition.z,
    189             targetPosition.x, targetPosition.y, targetPosition.z,
    190             up.x, up.y, up.z);
     188            targetPosition.x, targetPosition.y, targetPosition.z,
     189            up.x, up.y, up.z);
    191190
    192191  // switching back to Modeling Matrix
Note: See TracChangeset for help on using the changeset viewer.