Archived

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

red_sodium

Shaders 101

Recommended Posts

DISCLAIMER: Hyperlink to a Google search and I''ll eat you! Are there any good web pages/articles where i might i get no information you benefitted from learning about shaders, how and why to write them, and which language I should use for different purposes. Thankyou. Red Sodium

Share this post


Link to post
Share on other sites
My favorite IDE will support GLSL soon, it supports HLSL right now.

I think this will be a good start, they have LOTS AND LOTS of samples. Most of the samples will work with Geforce FX (but not all). All the demos will run on ATi (dx9 cards).

It's pretty easy to create your own stuff too.I think this had a decent intro

If you want more reason on why you should learn shaders, read this (or atleast look at the pictures)
http://www.ati.com/developer/gdc/D3DTutorial10_Half-Life2_Shading.pdf

[edited by - ngill on May 26, 2004 10:47:30 AM]

Share this post


Link to post
Share on other sites
The Orange book?

By the way, are all shaders uniform in their minimum specifications, etc (like, needing a certain level of graphics card) and just use different languages to achieve the same purpose?

Dowloading the CG toolkit now and also FX composer. Are these recommended? I''ve also been reading through articles but this is mostly on the theory and techniques. I also want to check with you guys that Cg indeed works on other card brands than nVidia

Red Sodium

Share this post


Link to post
Share on other sites
I use Cg on 2 commecial game projects and it works fine even on ATI. Anyway, drivers have their own post compiler that compiles the shaders asm into machine code. So it is hard to output "unoptimizable code" from a shader compiler, since the driver compiler will eventually solve that (some people are paid fulltime doing this).
take a look at the extended interface demos with source in the nvidia Cg toolkit.

Anyway you go, keep in mind that hight level shaders languages are the way to go.

Share this post


Link to post
Share on other sites
quote:
Original post by Pipo DeClown
quote:
Original post by _DarkWIng_
Google

You should never let your fears become the boundaries of your dreams.


LMAO.


Did you see where the hyperlink links to?



You should never let your fears become the boundaries of your dreams.

Share this post


Link to post
Share on other sites
Actually, I was hoping to use Cg because it is portable (apparently).

Yes I did see that link, but it didn''t look very serious, but once you take a proper look it''s much better , thanks.

Is there an online version of the "Orange Book"?

Red Sodium

Share this post


Link to post
Share on other sites
quote:
Original post by red_sodium
Actually, I was hoping to use Cg because it is portable (apparently).


HLSL, Cg, and glslang are all nearly identical. It''s not going to take much extra effort to go from one to the other.

Share this post


Link to post
Share on other sites
HLSL and CG are very similar. GLSlang is somewhat different, although it applies to the same problem domain, and thus share a number of design traits.

I found that downloading the NVIDIA SDK and the RenderMonkey and the DirectX SDK and picking apart their different samples taught me everything I needed to know about shader implementation. Growing up on the POV-Ray shader description language taught me everything I know about what I actually want the shaders to do (which is a distinctly separate skill!)

Share this post


Link to post
Share on other sites

a rendermonkey version with GLSL support is out, already; a link was posted some days ago.
the orange book is a must have; go out and buy it, if you don''t have it already.


DJSnow
---
this post is manually created and therefore legally valid without a signature

Share this post


Link to post
Share on other sites