Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jan 17, 2007, 5:52:08 PM (17 years ago)
Author:
muellmic
Message:

1) the centerpoint of the radar is now the centerpoint of the camera, so the enemies won't move in the radar when the player is moving; 2)fovy and cameradistance of each viewmode can now be set dynamically. so one would't have to readjust the fovy for each viewmode, when it has been manually changed once. (it's better to just change the fovy or distance for the viewmode where you need it); 3)unlike in the last revision, it doesnt have a soft- zoom- effect when setting a fovy anymore.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/playability/src/world_entities/camera.h

    r10237 r10270  
    3636
    3737  Camera();
     38  Camera(const TiXmlElement* root);
    3839  virtual ~Camera();
    3940
     
    4647
    4748  /** @param fovy new field of view factor (in degrees) */
    48   void setFovy(float fovy) { this->fovy = fovy; };
     49  inline void setFovy(float fovy)
     50  {
     51    this->fovy = fovy;
     52    this->toFovy = fovy;
     53  };
    4954  /** @param fovy new field of view factor (in degrees) to iterate to */
    5055  void setToFovy(float toFovy) { this->toFovy = toFovy; };
     
    6772  void process(const Event &event);
    6873
     74  //virtual void loadParams(const TiXmlElement* root);
     75
     76  void              setViewTopFovy(float fovy);
     77  void              setViewLeftFovy(float fovy);
     78  void              setViewRightFovy(float fovy);
     79  void              setViewBehindFovy(float fovy);
     80  void              setViewFrontFovy(float fovy);
     81  void              setViewNormalFovy(float fovy);
     82
     83  void              setViewTopDistance(float Distance);
     84  void              setViewLeftDistance(float Distance);
     85  void              setViewRightDistance(float Distance);
     86  void              setViewBehindDistance(float Distance);
     87  void              setViewFrontDistance(float Distance);
     88  void              setViewNormalDistance(float Distance);
     89
    6990private:
     91
     92  void              init();
     93
    7094  CameraTarget*     target;          //!< The Target of the Camera (where this Camera Looks at)
    7195
     
    84108  Vector            viewVector;      //!< the direction of the camera view
    85109  Vector            upVector;        //!< direction of the up vector
     110
     111  float             viewTopFovy;
     112  float             viewLeftFovy;
     113  float             viewRightFovy;
     114  float             viewBehindFovy;
     115  float             viewFrontFovy;
     116  float             viewNormalFovy;
     117
     118  float             viewTopDistance;
     119  float             viewLeftDistance;
     120  float             viewRightDistance;
     121  float             viewBehindDistance;
     122  float             viewFrontDistance;
     123  float             viewNormalDistance;
     124 
    86125};
    87126
Note: See TracChangeset for help on using the changeset viewer.