When Cg and HLSL were first created they were pretty much identical. Since D3D10 however they have diverged quite a bit.
Why use Uber Shaders? Why not one giant shader with some ifs.
Started by ill, Apr 26 2012 01:41 AM
21 replies to this topic
Sponsor:
#22 Moderators - Reputation: 13554
Posted 30 April 2012 - 01:31 AM
HLSL and Cg are almost exactly the same language -- both Microsoft and nVidia cooperated to create a "high level shading language" together. When they were done, MS published their version under the name "DirectX HLSL" and nVidia published theirs under the name "nVidia Cg", but they were both almost the same language (with different supporting tools/APIs/extensions).So Cg is similar to HLSL?
Edited by Hodgman, 30 April 2012 - 01:47 AM.






