Skip to main content

Questions tagged [directxmath]

DirectXMath API provides common linear algebra and graphics math operations to DirectX applications

Filter by
Sorted by
Tagged with
1 vote
1 answer
378 views

This question is about planar shadows as explained in Frank Luna's DX11 book. The author presents the 4x4 shadow matrix, whose bottom right element is n\$\cdot\$L (where n is the plane's normal and L ...
Daniel's user avatar
  • 131
0 votes
1 answer
179 views

I've just implemented a simple algorithm to calculate terrain vertex normals and I'm using diffuse and ambient light currently, but for some reason the squares that make up my terrain are visible when ...
Rafael Ferreira's user avatar
0 votes
0 answers
103 views

Dears, I am facing a performance problem when I try to access cell 42 and 43 in XMMATRIX define in DirectXMath.h. The frames dropped by 100 FPS. Here is my code: ...
Ahmed Elhamy's user avatar
2 votes
1 answer
2k views

I'm drawing a health bar on top of each player. I transform 3d position to 2d. I would like to draw it smaller when distance increases. Any simple math for that? Let's say bar width is 30 and height ...
Konrad's user avatar
  • 140
1 vote
0 answers
151 views

[][]2 there's problem calculating tangent space and look.... it seems there is no problem with UV code and my shader is 100% no problem. I just copy and pasted tutorial code which works well.. I ...
yunsungjuns's user avatar
0 votes
2 answers
372 views

Since XMFLOAT2 is just a structure, I'm sure it does not have operator overloading which is what I need to make things a lot simpler. Is there something like ...
user100749's user avatar
1 vote
1 answer
2k views

Let's say we have a 4-by-4 matrix \$A\$ which represents some transformation. We can use this matrix to transform a vector in two ways. \$Ax\$ by assuming \$x\$ is a 4-by-1 column vector. \$xA\$ by ...
John Leidegren's user avatar
1 vote
2 answers
2k views

I'm looking for a basic example of rotating camera using the mouse. the only problem is I'm not sure of how to rotating the camera around it target. should i do this by an algorithm or is there a ...
SukottoSama's user avatar
-1 votes
1 answer
166 views

How would I go about simulating a planes movement in DirectX 9 using transforms (i.e. matrices). For example flying around an open space. When it moves it faces the direction it is going and ...
Nick's user avatar
  • 113
1 vote
1 answer
435 views

I.e. can I do this: XMMATRIX dxMat; Matrix myMat; std::memcpy(&myMat, &dxMat, sizeof(XMMATRIX)); std::memcpy(&dxMat, &myMat, sizeof(XMMATRIX)); <...
NPS's user avatar
  • 2,334