TAILIEUCHUNG - Microsoft XNA Game Studio Creator’s Guide- P11

Microsoft XNA Game Studio Creator’s Guide- P11:The release of the XNA platform and specifically the ability for anyone to write Xbox 360 console games was truly a major progression in the game-programming world. Before XNA, it was simply too complicated and costly for a student, software hobbyist, or independent game developer to gain access to a decent development kit for a major console platform. | 278 MICROSOFT XNA GAME STUDIO CREATOR S GUIDE vector that stores a rotation around an axis. Quaternion math is used to calculate an increment to update the camera s Look vector. We can express the value of the Look vector like this Look View - Position By rearranging this equation we can say the following View Look Position If the quaternion represents the updated Look vector then Updated View Updated Look Vector Position Updated Look Vector The formula for calculating the updated Look vector is qRotation qLook qRotation qRotation is the conjugate of qRotation Each of the three operands will be discussed next. Local Rotation Quaternion The first quaternion that is used to calculate the updated Look vector qRotation is a local rotation. Quaternion theory provides a formula for computing the local rotation. In this case the local rotation is generated using a direction vector for X Y and Z. Rotations about the X axis are applied using the Look vector. Rotations about the Y axis are applied using the Right direction vector. The rotation angle stored in the W component is obtained from the deviation of the mouse or thumbstick from the center of the window. With this information we can generate the local rotation by writing the following cos MouseDeviationFromCenter 2 sin MouseDeviationFromCenter 2 sin MouseDeviationFromCenter 2 sin MouseDeviationFromCenter 2 Using the Look Vector as a Quaternion The next quaternion used in the formula for the updated Look vector is based on the Look direction 0 CHAPTER 17 Conjugate Quaternion A conjugate quaternion is used to calculate the updated Look vector. The conjugate is created by negating a quaternion vector s X Y and Z components Quaternion conjugate Quaternion Product The equation for multiplying two quaternion is as follows

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.