Saturday, March 5, 2011
Diary During Summer Vacation 3
I was working on solving two technical problems: how to get right rotation so that the string will not be stretched; and how to convert a 2D position on the screen to a 3D position in the scene so that the new points added by the user can be as right as what the user expects. Having tried many methods, however the fisrt problem remain unsolved. Regarding the second problem, we already have WorldMatrix, ProjectionMatrix and ViewMatrix. Given only a 2D position, with these there difined matrics there is obviously a whole set of possible 3D positions that I can use. By uising the Unproject() method, passing these matrics as parameters, I now can get exactly the right 3D position. The program is now much more elegant: it is now easy to really add points to form a knot. The first problem is unsolved yet. I would like to go seek help from Casey, the coordinator of CSCI356. I think he would give me some help with matrix calculation in XNA.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment