a question about string and annotations in effect

Started by
1 comment, last by Etnu 19 years, 8 months ago
I have learned the effect file now, but I cann't understand the "string" and "annotation" in effect very much, and how and when should I use these two types. Is there any tutorial that show how to use them? thank you
Advertisement
Annotations are hints to the application as to what certain shader parameters are used for. For example, FX Composer and RenderMonkey both check the annotations of the .fx file to label parameters in their GUI's. A scalar parameter that has defined min and max values could have a slider associated with it, or a diffuse color could have a fancy color wheel associated with it by the main program.

You don't need annotations for shaders to work. But they're usefull when creating tools for artists to manipulate things.

As far as tutorials go, there aren't any. The Summer 2004 SDK docs have sections on standard annotations and semantics that you can look at. The docs are pretty understandable for the main kinds of objects an shader IDE would need to show artists and the docs will get better with time.

Annotations and semantics have been a gray area of shader development because there was no real standard. But hopefully with the latest SDK update, both Nvidia and ATI will adjust their shader tools to match the new standard. I think Nvidia just released (or is about to release) an updated version of FX Composer that adheres to the new standard. ATI will probably follow suit soon.

neneboricua
FX Composer follows MS annotation standards, and Rendermonkey should with the next release.

---------------------------Hello, and Welcome to some arbitrary temporal location in the space-time continuum.

This topic is closed to new replies.

Advertisement