   D3DFVF_NORMAL
  Hi, I have a basic question.I understand vertex position is calculated in GPUby g_pd3dDevice->SetTransform( D3DTS_WORLD, &matWorld );So it moved somewhere...What about normal vector when I use D3DFVF_NORMAL flag.Is it also calculated every frame in GPU by matWorld ?If so, I don't have to re-calculate normal vector every frame when object move.It is TLVertex ?[edited by - tsurudome on March 24, 2004 7:05:49 AM][edited by - tsurudome on March 24, 2004 7:07:28 AM]
  mat world is just a matrixu set the whole vertex stuff manually, and the normals are usually -1,-1,-1the matrix just moves stuff for you while its already set, you can''t modify vertices using a matrix, just move and rotate, scale etc on how it is already setjust imagine matrices moving objects only ;quote:Original post by johnnyBravo  mat world is just a matrixu set the whole vertex stuff manually, and the normals are usually -1,-1,-1I think he knows that it''s a matrix... and -1,-1,-1 isn''t a valid normal, never mind a usual one.  There isn''t a usual normal.To tsurudome, yes the world transform transforms the normals too.  The translation is ignored.  If you use scaling in your world matrix you will need to set renderstate D3DRS_NORMALIZENORMALS to ensure lighting occurs properly. ;  Thanks Namethatnobodyelsetook~Actually, I guessed so after thinking for few hours. But I wasn't sure that because there is no way to look intowhat's going on in GPU.And your answer all clear to me.   [edited by - tsurudome on March 24, 2004 11:51:08 AM]