Jump to content
  • Advertisement
Sign in to follow this  
feiyurainy

a question about string and annotations in effect

This topic is 5066 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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

Share this post


Link to post
Share on other sites
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

Share this post


Link to post
Share on other sites
FX Composer follows MS annotation standards, and Rendermonkey should with the next release.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!