Changeset 10272 in orxonox.OLD for branches/camera/src/world_entities/cameraman.cc
- Timestamp:
- Jan 17, 2007, 6:16:08 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/camera/src/world_entities/cameraman.cc
r10259 r10272 21 21 #include "sound_engine.h" 22 22 23 ObjectListDefinition(cameraman); 24 23 25 24 26 cameraman::cameraman() 25 27 { 28 this->registerObject(this, cameraman::_objectList); 29 30 this->nearClip = 1.0; 31 this->farClip = 1000.0; 32 26 33 currentCam=State::getCamera(); 27 34 this->cameras.push_back(currentCam); 28 currentCam->target->detach();29 35 State::setCamera(currentCam, currentCam->getTarget()); 36 // currentCam->setClipRegion(nearClip, farClip); 30 37 } 31 38 … … 36 43 this->cameras.push_back(new Camera()); 37 44 cameras[cameras.size()-1]->target->detach(); 38 39 40 41 cout << cameras[1]->getAbsCoorX() << "," << cameras[1]->getAbsCoorY() << "," << cameras[1]->getAbsCoorZ() << endl << cameras[1]->target->getAbsCoorX() << endl; 45 cameras[cameras.size()-1]->setClipRegion(nearClip, farClip); 42 46 43 47 } … … 97 101 98 102 103 104 void cameraman::setClipRegion(float nearCli, float farCli) 105 { 106 this->nearClip=nearCli; 107 this->farClip=farCli; 108 109 for(int i = 0; i < this->cameras.size(); i++) 110 cameras[i]->setClipRegion(nearCli, farCli); 111 } 112 113 99 114 void cameraman::jumpCurrCam(int x, int y, int z) 100 115 {
Note: See TracChangeset
for help on using the changeset viewer.