Cel Shading - Convert GLSL to CG

ReinaldoEumesmo4002

08-11-2007 10:37:05

I have a project in C++ and Im using GLSL to make cel shading, but this only work with OpenGL and I need to work with DirectX too.

Anybody know how i convert GLSL to CG, or have a tutorial about CG and GLSL ?

thanks

Lioric

10-11-2007 02:13:58

Both are high-level languages, if you know what the methods of the GLSL in your shader are doing, then use the CG reference to map the methods and convert them to CG, download the CG documentation (in the CG Toolkit), in there you can see the "CG Standard Library Functions" chapter (in the pdfs) were you can see the reference for the methods (and complete documentation on what is needed when writing CG shaders)