D3DXMESH vertex color changing

Started by
-1 comments, last by bartiss 18 years, 4 months ago
Hi, Is there any way to change vertex color in a d3dxmesh loaded from an x-file? After some experiments I've figured out that the vertex are in fvf as below: XYZ|NORMAL|TEX1 and these are the only things I can change right now. But my app uses dynamic lighting and that works on per-vertex basis (I guess xyz and normal are enough) so vertex colors got to be somewhere. Where? And is it available for me? Or maybe I have to make my own vertex format with color and convert the mesh's vertex buffer to it? I need access the colors directly (I have to find the time to learn those famous shaders ;-) ) to implement a simple shadow system. I know there are better methods but I'm trying to understand all this a little deeper. Thanks Bartiss

This topic is closed to new replies.

Advertisement