how to get the entry point function .fx file ?

Started by
1 comment, last by luasitdown 18 years, 3 months ago
Is there the function like getvsmain() or getpsmain()?? another question : how to traverse tech in a .fx file? or how to get technique number so that I can trverse by technique index.
Advertisement
Quote:
Is there the function like getvsmain() or getpsmain()??

Not that I know of.

Quote:
another question : how to traverse tech in a .fx file? or how to get technique number so that I can trverse by technique index.

When you are using the ID3DXEffect interface or the Effect class for Managed DirectX, when you call Begin method in the Effect class it returns the number of passes in the effect to completely render the effect.
So what people do normally is have a for loop that will loop across the returned number of passes in the effect.

edit:
For your technique, the only way I can think of is when you are writing the technique to give it an appropriate name and then you can parse the file or just encode a comment or something with the amount of techniques in the file and their appropriate names.

I hope this helps.
Take care.

[Edited by - Armadon on January 2, 2006 8:11:00 AM]
Begin return pass number other than technique number

[Edited by - luasitdown on January 2, 2006 6:20:45 AM]

This topic is closed to new replies.

Advertisement