- Timestamp:
- Mar 23, 2005, 1:55:52 AM (20 years ago)
- Location:
- orxonox/trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/camera.cc
r3639 r3641 36 36 this->target = new CameraTarget(); 37 37 38 this->toRelCoor = new Vector; 39 40 this->setFovy(60); 38 this->setFovy(90); 41 39 this->setAspectRatio(1.2f); 42 40 this->setClipRegion(.1, 2000); 41 43 42 this->setViewMode(VIEW_NORMAL); 44 45 43 } 46 44 … … 106 104 case VIEW_NORMAL: 107 105 this->toFovy = 60.0; 108 *this->toRelCoor = Vector (-10, 5, 0);106 this->toRelCoor = Vector (-10, 5, 0); 109 107 break; 110 108 case VIEW_BEHIND: 111 109 this->toFovy = 90.0; 112 *this->toRelCoor = Vector (-6, 2, 0);110 this->toRelCoor = Vector (-6, 2, 0); 113 111 break; 114 112 case VIEW_FRONT: 115 113 this->toFovy = 95.0; 116 *this->toRelCoor = Vector (10, 5, 0);114 this->toRelCoor = Vector (10, 5, 0); 117 115 break; 118 116 case VIEW_LEFT: 119 117 this->toFovy = 90; 120 *this->toRelCoor = Vector (0, 5, -10);118 this->toRelCoor = Vector (0, 2, -10); 121 119 break; 122 120 case VIEW_RIGHT: 123 121 this->toFovy = 90; 124 *this->toRelCoor = Vector (0, 5, 10);122 this->toRelCoor = Vector (0, 2, 10); 125 123 break; 126 124 } … … 136 134 dt /= 1000; 137 135 this->fovy += (this->toFovy - this->fovy) * dt; 136 Vector tmp = this->getRelCoor() + (this->toRelCoor - this->getRelCoor()) * dt; 137 this->setRelCoor(&tmp); 138 PRINTF(0)("%f %f %f\n", tmp.x, tmp.y, tmp.z); 138 139 } 139 140 -
orxonox/trunk/src/camera.h
r3639 r3641 8 8 9 9 #include "p_node.h" 10 #include "vector.h" 10 11 11 12 class World; … … 28 29 float farClip; //!< The far clipping plane. 29 30 30 Vector *toRelCoor;31 Vector toRelCoor; 31 32 float toFovy; 32 33 -
orxonox/trunk/src/story_entities/world.cc
r3640 r3641 307 307 Vector* cameraOffset = new Vector (-2, 2, 0); 308 308 this->localCamera->setRelCoor (cameraOffset); 309 this->localCamera->setFovy(100);310 309 311 310 /*monitor progress*/
Note: See TracChangeset
for help on using the changeset viewer.