Archived

This topic is now archived and is closed to further replies.

Daedalus

Vertex Shader Question

Recommended Posts

I''ve been pouring over all the vertex shader resources I could find over the last few days trying to teach myself whether an idea I had for a shader is possible within the limitations of the present vertex shader system. I think I finally see how I can accomplish my goal but I have one last problem. In order to run my shader algorithm I need to have the coordinates of all 6 of the vertex''s neighbors and their respective normals (I''m assuming a mesh where all vertexs have at most a valence of 6). I can''t see how I can get a new set of neighbor info into the shader (whether through the input buffer of the constant buffer) for each vertex. Is this possible? The one way I thought about it was to design a FVF that stored all the neighbor info as well as the vertex''s info. Obviously it''d be a huge FVF format and pretty much useless. Any help is greatly appreciated. -Daedalus

Share this post


Link to post
Share on other sites
At first thought, it seems pretty difficult if you want to keep the vertex sized sane. Is there any way to preprocess the vertices and store some metadata in the vertex?

Also, it will help if you explain what you are actually trying to do. Many times, the good solution is not what you''d expect.

Share this post


Link to post
Share on other sites