Changeset 3023 in orxonox.OLD for orxonox/branches/bezierTrack
- Timestamp:
- Nov 30, 2004, 1:13:48 AM (20 years ago)
- Location:
- orxonox/branches/bezierTrack/src
- Files:
-
- 1 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/bezierTrack/src/Makefile.am
r3018 r3023 7 7 bin_PROGRAMS=orxonox 8 8 9 orxonox_SOURCES=orxonox.cc world.cc player.cc data_tank.cc world_entity.cc vector.cc camera.cc collision.cc command_node.cc ini_parser.cc keynames.cc track.cc base_entity.cc game_loader.cc campaign.cc story_entity.cc object.cc environment.cc array.cc material.cc list.cc curve.cc 10 noinst_HEADERS=ability.h data_tank.h npc.h stdincl.h ai.h environment.h orxonox.h synchronisable.h base_entity.h error.h player.h track.h camera.h ini_parser.h power_up.h vector.h collision.h keynames.h proto_class.h world.h command_node.h list.h shoot_laser.h world_entity.h coordinates.h message_structures.h shoot_rocket.h object.h array.h material.h list_template.h story_entity.h story_def.h game_loader.h campaign.h curve.h 9 orxonox_SOURCES=orxonox.cc \ 10 world.cc \ 11 player.cc \ 12 data_tank.cc \ 13 world_entity.cc \ 14 vector.cc \ 15 camera.cc \ 16 collision.cc \ 17 command_node.cc \ 18 ini_parser.cc \ 19 keynames.cc \ 20 track.cc \ 21 base_entity.cc \ 22 game_loader.cc \ 23 campaign.cc \ 24 story_entity.cc \ 25 object.cc \ 26 environment.cc \ 27 array.cc \ 28 material.cc \ 29 list.cc \ 30 curve.cc \ 31 coordinates.cc 32 33 noinst_HEADERS=ability.h \ 34 data_tank.h \ 35 npc.h \ 36 stdincl.h \ 37 ai.h \ 38 environment.h \ 39 orxonox.h \ 40 synchronisable.h \ 41 base_entity.h \ 42 error.h \ 43 player.h \ 44 track.h \ 45 camera.h \ 46 ini_parser.h \ 47 power_up.h \ 48 vector.h \ 49 collision.h \ 50 keynames.h \ 51 proto_class.h \ 52 world.h \ 53 command_node.h \ 54 list.h \ 55 shoot_laser.h \ 56 world_entity.h \ 57 coordinates.h \ 58 message_structures.h \ 59 shoot_rocket.h \ 60 object.h \ 61 array.h \ 62 material.h \ 63 list_template.h \ 64 story_entity.h \ 65 story_def.h \ 66 game_loader.h \ 67 campaign.h \ 68 curve.h 11 69 12 70 -
orxonox/branches/bezierTrack/src/Makefile.in
r3018 r3023 60 60 campaign.$(OBJEXT) story_entity.$(OBJEXT) object.$(OBJEXT) \ 61 61 environment.$(OBJEXT) array.$(OBJEXT) material.$(OBJEXT) \ 62 list.$(OBJEXT) curve.$(OBJEXT) 62 list.$(OBJEXT) curve.$(OBJEXT) coordinates.$(OBJEXT) 63 63 orxonox_OBJECTS = $(am_orxonox_OBJECTS) 64 64 orxonox_LDADD = $(LDADD) … … 69 69 @AMDEP_TRUE@ ./$(DEPDIR)/base_entity.Po ./$(DEPDIR)/camera.Po \ 70 70 @AMDEP_TRUE@ ./$(DEPDIR)/campaign.Po ./$(DEPDIR)/collision.Po \ 71 @AMDEP_TRUE@ ./$(DEPDIR)/command_node.Po ./$(DEPDIR)/curve.Po \ 71 @AMDEP_TRUE@ ./$(DEPDIR)/command_node.Po \ 72 @AMDEP_TRUE@ ./$(DEPDIR)/coordinates.Po ./$(DEPDIR)/curve.Po \ 72 73 @AMDEP_TRUE@ ./$(DEPDIR)/data_tank.Po \ 73 74 @AMDEP_TRUE@ ./$(DEPDIR)/environment.Po \ … … 185 186 AM_CXXFLAGS = "-I/usr/X11R6/include" 186 187 AM_LDFLAGS = "-L/usr/Mesa-6.0.1/lib -L/usr/X11R6/lib -lXt -lX11" $(MWINDOWS) 187 orxonox_SOURCES = orxonox.cc world.cc player.cc data_tank.cc world_entity.cc vector.cc camera.cc collision.cc command_node.cc ini_parser.cc keynames.cc track.cc base_entity.cc game_loader.cc campaign.cc story_entity.cc object.cc environment.cc array.cc material.cc list.cc curve.cc 188 noinst_HEADERS = ability.h data_tank.h npc.h stdincl.h ai.h environment.h orxonox.h synchronisable.h base_entity.h error.h player.h track.h camera.h ini_parser.h power_up.h vector.h collision.h keynames.h proto_class.h world.h command_node.h list.h shoot_laser.h world_entity.h coordinates.h message_structures.h shoot_rocket.h object.h array.h material.h list_template.h story_entity.h story_def.h game_loader.h campaign.h curve.h 188 orxonox_SOURCES = orxonox.cc \ 189 world.cc \ 190 player.cc \ 191 data_tank.cc \ 192 world_entity.cc \ 193 vector.cc \ 194 camera.cc \ 195 collision.cc \ 196 command_node.cc \ 197 ini_parser.cc \ 198 keynames.cc \ 199 track.cc \ 200 base_entity.cc \ 201 game_loader.cc \ 202 campaign.cc \ 203 story_entity.cc \ 204 object.cc \ 205 environment.cc \ 206 array.cc \ 207 material.cc \ 208 list.cc \ 209 curve.cc \ 210 coordinates.cc 211 212 noinst_HEADERS = ability.h \ 213 data_tank.h \ 214 npc.h \ 215 stdincl.h \ 216 ai.h \ 217 environment.h \ 218 orxonox.h \ 219 synchronisable.h \ 220 base_entity.h \ 221 error.h \ 222 player.h \ 223 track.h \ 224 camera.h \ 225 ini_parser.h \ 226 power_up.h \ 227 vector.h \ 228 collision.h \ 229 keynames.h \ 230 proto_class.h \ 231 world.h \ 232 command_node.h \ 233 list.h \ 234 shoot_laser.h \ 235 world_entity.h \ 236 coordinates.h \ 237 message_structures.h \ 238 shoot_rocket.h \ 239 object.h \ 240 array.h \ 241 material.h \ 242 list_template.h \ 243 story_entity.h \ 244 story_def.h \ 245 game_loader.h \ 246 campaign.h \ 247 curve.h 248 189 249 all: all-am 190 250 … … 259 319 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision.Po@am__quote@ 260 320 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/command_node.Po@am__quote@ 321 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coordinates.Po@am__quote@ 261 322 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/curve.Po@am__quote@ 262 323 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data_tank.Po@am__quote@ -
orxonox/branches/bezierTrack/src/camera.cc
r3013 r3023 32 32 bound = NULL; 33 33 /* give it some physical live */ 34 m = 10; 35 a = new Vector(0.0, 0.0, 0.0); 36 v = new Vector(0.0, 0.0, 0.0); 37 fs = new Vector(0.0, 0.0, 0.0); 34 mass = 10; 35 acceleration = new Vector(0.0, 0.0, 0.0); 36 velocity = new Vector(0.0, 0.0, 0.0); 38 37 cameraMode = NORMAL; 39 38 deltaTime = 3000.0; … … 244 243 // ===== second camera control calculation option 245 244 /* 246 gluLookAt(actual_place. r.x, actual_place.r.y, actual_place.r.z,247 plBound->r.x, plBound->r.y, plBound->r.z,245 gluLookAt(actual_place.pos.x, actual_place.pos.y, actual_place.pos.z, 246 bound->pos.x, bound->pos.y, bound->pos.z, 248 247 0.0, 0.0, 1.0); 249 */ 248 */ 250 249 251 250 glMatrixMode (GL_MODELVIEW); -
orxonox/branches/bezierTrack/src/camera.h
r2636 r3023 23 23 enum CAMERA_MODE {NORMAL, SMOTH_FOLLOW, STICKY, ELLIPTICAL}; 24 24 25 class Camera { 25 class Camera : public Coordinate 26 { 26 27 private: 27 28 WorldEntity* bound; //!< the WorldEntity the Camera is bound to … … 31 32 32 33 /* physical system - not needed yet */ 33 float m; //!< mass 34 Vector *fs; //!< seil-kraft 35 Vector *a; //!< acceleration 36 Vector *v; //!< velocity 34 float mass; //!< mass 35 Vector *acceleration; //!< acceleration 36 Vector *velocity; //!< velocity 37 37 38 38 /* elliptical camera mode variables */ -
orxonox/branches/bezierTrack/src/coordinates.h
r3013 r3023 34 34 } Placement; 35 35 36 37 /////////////////////////////////////////////////////////////////// 38 //////// NEW COORDINATES, because the old ones were a bit fuzy // 39 /////////////////////////////////////////////////////////////////// 40 enum COORD_TYPE {WORLD, TRACK, LOCAL}; 41 42 typedef struct 43 { 44 Vector position; 45 Quaternion rotation; 46 } Coord; 47 48 class Coordinate 49 { 50 private: 51 Coord worldCoord; 52 53 public: 54 55 void setCoord (Coord coordinate, COORD_TYPE cType); 56 void setPosition (Vector position, COORD_TYPE cType); 57 void setRotation (Quaternion rotation, COORD_TYPE cType); 58 59 Coord getCoord (COORD_TYPE cType) const; 60 Vector getPosition (COORD_TYPE cType) const; 61 Quaternion getRotation (COORD_TYPE cType) const; 62 }; 63 64 65 66 67 68 //! World coordinates: 69 /** 70 Absolute coordinates in 3D-space are defined as the coordinates, an Entity has in respect to the absolute Zero point 71 */ 72 typedef struct 73 { 74 Vector position; //!< absolute position of the Object (the one opengl has to know) 75 Quaternion rot; //!< absolute rotation 76 } WorldCoord; 77 78 typedef struct 79 { 80 Vector position; //!< The Vector from the current Path-Position to the Entity. (worldCoord->position - track->worldCoord->position) 81 Quaternion rot; //!< rotation an entity has to the track. 82 } TrackCoord; 83 84 typedef struct 85 { 86 Vector position; //!< the coordinate to the object itself. This shoud be 0 for an entity. (can be used for explosions on the ship, shoot and so on.) 87 Quaternion rot; //!< the Rotation of an object itself. (to easily shoot in different directions) 88 } LocalCoord; 89 36 90 #endif -
orxonox/branches/bezierTrack/src/curve.cc
r3019 r3023 12 12 main-programmer: Benjamin Grauer 13 13 co-programmer: ... 14 15 Quaternion code borrowed from an Gamasutra article by Nick Bobick and Ken Shoemake 14 15 TODO: 16 local-Time implementation 17 closed Bezier Curve 18 NURBS 19 16 20 */ 17 21 -
orxonox/branches/bezierTrack/src/curve.h
r3019 r3023 18 18 int nodeCount; 19 19 Vector curvePoint; 20 float localTime; //!< if the time of one point is asked more than once the programm will not calculate it again. 20 21 21 22 struct PathNode -
orxonox/branches/bezierTrack/src/world.cc
r3018 r3023 104 104 105 105 track->addPoint (Vector(0, 0, 0)); 106 track->addPoint (Vector(10, 0, 0)); 107 track->addPoint (Vector(11, 0, 0)); 108 track->addPoint (Vector(12, 0, 0)); 109 track->addPoint (Vector(13, 0, 0)); 110 track->addPoint (Vector(20, 0, 0)); 111 track->addPoint (Vector(30, 0, 0)); 106 track->addPoint (Vector(10, -5, 0)); 107 track->addPoint (Vector(20, 5, 0)); 108 track->addPoint (Vector(30, -5, 0)); 112 109 track->addPoint (Vector(40, 0, 0)); 113 110 track->addPoint (Vector(60, 0, 0));
Note: See TracChangeset
for help on using the changeset viewer.