While I was going over some older DirectX code, I came by the functions D3DXVec3Transform and D3DXVec3TransformCoord. Upon looking up the descriptions for them, they seemed rather similar but I don't see what the difference between the two are. Can someone please explain what is the difference between D3DXVec3Transform and D3DXVec3TransformCoord are, along with the math behind them?
相关问题
- Sorting 3 numbers without branching [closed]
- How to compile C++ code in GDB?
- Why does const allow implicit conversion of refere
- thread_local variables initialization
- What uses more memory in c++? An 2 ints or 2 funct
相关文章
- Class layout in C++: Why are members sometimes ord
- How to mock methods return object with deleted cop
- Which is the best way to multiply a large and spar
- C++ default constructor does not initialize pointe
- ceil conterpart for Math.floorDiv in Java?
- Selecting only the first few characters in a strin
- What exactly do pointers store? (C++)
- Converting glm::lookat matrix to quaternion and ba
When you transform a 3D vector by matrix it results in a 4D vector where w!=1
a 3D vector can be described as 4D vector where w=1.
D3DXVec3Transform returns the 4D vector where w!=1. D3DXVec3TransformCoord gets the 4D vector and the projects it onto w=1 to make it 3D vector.
EDIT: And here is the paper I google'd and found if interested in how to do the transformation: http://www.heldermann-verlag.de/jgg/jgg01_05/jgg0404.pdf