TWiki home TWiki > Team5 > ProjectTwo (r1.5) TWiki webs:
Main | TWiki | Know | Sandbox
Team5 . { Changes | Index | Search | Go }
Beginning preliminary work on the project. I've initialized the CVS repository with project/solution files; geometry.cpp/.h are in and added; openGL.cpp is also in CVS but is not included in the project.

-- BrianYoung - 02 Oct 2004

Divided work for basic stuff, and discussed how actual classes are divided.

-- BrianYoung - 02 Oct 2004

Well, because I don't know how C++ vectors work, there's a bug in the world destructor. This note is mainly here for my reference so I can find it later. I also massaged the files to make dependencies work, and added return false to all the undone collision detections so we could at least get a build.

Instead of just boolean collision detection functions, do we want two sets: alphaCollide to return the time at which the collision will take place (1.0 being never) and normalCollide to return the normal vector it could occur with? Then in our timestep function, we call alphaCollide on all the triangles, decide which will collide first, then normalCollide on just that one.

-- BrianYoung - 04 Oct 2004 (let me know if I'm coming off as bossy)

Fixed the destructor bug; found that the vector was storing copies of our Triangles after all. Also implemented the world timer, and a world pause. Current state of project - white ball on green background, press space to make the ball start or stop moving.

Also, in golf.cpp there is commented code for timeStep that just needs alphaCollide and normalCollide implemented, and will be ready to go. Next up - make the ball feel gravity!

-- BrianYoung - 05 Oct 2004

GolfWorld? and GolfBall? classes are done. World is stored as global _world; ball is stored as _world._ball. CollisionDetector? should have an alphaCollide function that takes a ball and a triangle and returns the float betewen zero and one when they will collide; and a normalCollide function that takes the same and returns the normal that they'll collide with. After that, uncommenting the code in timeStep should make it work nice and happy (and removing the _ball.move(1) at the end).

I can answer questions. I have an algorithms test, thoguh, aso I may not get much coding time in. I'm in a big hurry.

Brian

Topic ProjectTwo . { Edit | Attach | Ref-By | Printable | Diffs | r1.31 | > | r1.30 | > | r1.29 | More }
Revision r1.5 - 06 Oct 2004 - 01:31 GMT - BrianYoung
Parents: WebHome
Copyright © 1999-2003 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback.