Changeset 7013 in orxonox.OLD for trunk/src/world_entities
- Timestamp:
- Feb 3, 2006, 12:59:42 PM (19 years ago)
- Location:
- trunk/src/world_entities
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/camera.cc
r7009 r7013 146 146 { 147 147 //update frustum plane 148 this->viewVector = this->getAbsCoor() - this->target->getAbsCoor();149 this->frustumPlane = Plane(this->viewVector, this->getAbsCoor() + Vector(-70.0,0.0,0.0));148 this->viewVector = (this->getAbsCoor() - this->target->getAbsCoor()).getNormalized(); 149 this->frustumPlane = Plane(this->viewVector, this->getAbsCoor() + this->viewVector * 3.0); 150 150 151 151 this->upVector = this->getAbsDirV(); -
trunk/src/world_entities/camera.h
r7009 r7013 48 48 inline const Plane& getViewFrustum() const { return this->frustumPlane; } 49 49 50 inline float distance(const Vector& distance) const { return this->frustumPlane.distancePoint(distance); } 51 inline float distance(const PNode* node) const { return distance(node->getAbsCoor()); } 50 52 51 53 void tick(float dt);
Note: See TracChangeset
for help on using the changeset viewer.