Which shader compiler does Ogre use?
-
- Orc Shaman
- Posts: 788
- Joined: Mon Jan 18, 2010 6:06 pm
- Location: Costa Mesa, California
- x 24
Which shader compiler does Ogre use?
Does it use fxc or just cgc or a combination of both depending on the file? I'm trying to track down the cause of some shader errors..
- c6burns
- Beholder
- Posts: 1512
- Joined: Fri Feb 22, 2013 4:44 am
- Location: Deep behind enemy lines
- x 138
- Kojack
- OGRE Moderator
- Posts: 7157
- Joined: Sun Jan 25, 2004 7:35 am
- Location: Brisbane, Australia
- x 534
Re: Which shader compiler does Ogre use?
Ogre doesn't use a stand alone shader compiler like cgc or fxc, it uses the cg/opengl/directx libraries.
DirectX 9 HLSL shaders are compiled by calling D3DXCompileShader().
DirectX 11 HLSL shaders are compiled by calling CreateVertexShader(), CreatePixelShader(), CreateGeometryShader(), CreateDomainShader() or CreateHullShader() (members of ID3D11Device).
GLSL shaders are compiled by calling glCompileShaderARB().
CG shaders are compiled by calling cgCreateProgram().
DirectX 9 HLSL shaders are compiled by calling D3DXCompileShader().
DirectX 11 HLSL shaders are compiled by calling CreateVertexShader(), CreatePixelShader(), CreateGeometryShader(), CreateDomainShader() or CreateHullShader() (members of ID3D11Device).
GLSL shaders are compiled by calling glCompileShaderARB().
CG shaders are compiled by calling cgCreateProgram().
-
- Orc Shaman
- Posts: 788
- Joined: Mon Jan 18, 2010 6:06 pm
- Location: Costa Mesa, California
- x 24
Re: Which shader compiler does Ogre use?
Ah ok. Good to know. Thanks Kojack. Since you seem pretty knowledgeable about shaders, can you tell me where the errors I describe here come from? http://www.ogre3d.org/forums/viewtopic.php?f=2&t=80873