Thursday, May 19, 2005

Implementing SWIFT

Project stlViewer was modified to incorporate the SWIFT package. The project uses SWIFT to load two spherical objects from a given TRI file. The SWIFT source code was modified to allow the vertex data to be retreived from it. The program has a TRI file reader and stores data as a mesh. A function was added to return a struct, SOLID, that contains the array of every face and each face having 3 vertices.

stlViewer loads the two sphere objects and draws them using openGl. One sphere can be moved and when a collision occurs the console prints that a collision has occured.

SWIFT will be linked with haptic thread. The haptics thread will send the rotation and translation information to the graphics thread and the SWIFT package. This is because the only moving object is the haptic device/drilling tool. The SWIFT package offers a function that returns the distance between the two objects. This will be used as a spring force.

0 Comments:

Post a Comment

<< Home


Counters