pocketmoon66
Newcomer
cg Lives! Nvidia shader lang for PS3ZoinKs! said:No one said it's good. :?
DOGMA1138 said:cg Lives! Nvidia shader lang for PS3ZoinKs! said:No one said it's good. :?
:\
DOGMA1138 said:and why is that a good thing?
Yeah except you forget that some games get released on multiple platforms and their is no disadvantage aslong as you assume the compiler does a better job then the program at the machine level assembly.Chalnoth said:3. GLSL doesn't make as much sense because its primary advantage is the lack of an intermediate assembly language, which (in theory) allows better optimization for compiling across a variety of machines. But when you're only writing for one machine this advantage evaporates (though I think it's definitely the direction that all HLSL's on the PC should move).
Exactly what low level control do you want? most of the NV shader operation are almost exaclty map to equivilant PS3.0 instructions.2. Cg offers more low-level control than GLSL, giving developers better tools to work with.
Except that in that case, Cg is more portable than GLSL, as it'll map more easily to Microsoft's HLSL.bloodbob said:Yeah except you forget that some games get released on multiple platforms and their is no disadvantage aslong as you assume the compiler does a better job then the program at the machine level assembly.
Except the underlying hardware doesn't directly use the PS 3.0 instruction set. On a console you may want to do some tweaking at the most basic level.Exactly what low level control do you want? most of the NV shader operation are almost exaclty map to equivilant PS3.0 instructions.
How is Cg more portable? GLSL is completely platform independant as far as I know the Cg compiler currently only has profiles for NV_shaders,ARB assemble and the PS/VS assembly? So if you hardware can't run any of them your stuffed. Exactly which profile is Cg supposed to use for PS3?Chalnoth said:Except that in that case, Cg is more portable than GLSL, as it'll map more easily to Microsoft's HLSL.
Who says thats gonna be exposed currently there is no public Cg compiler that compiles directly to native hardware instruction so there is no reason to assume it is on the PS3 it will compile to the hardware level assembly.Except the underlying hardware doesn't directly use the PS 3.0 instruction set. On a console you may want to do some tweaking at the most basic level.
Do you think that Microsoft will allow an OpenGL driver for the XBox 2?bloodbob said:How is Cg more portable? GLSL is completely platform independantChalnoth said:Except that in that case, Cg is more portable than GLSL, as it'll map more easily to Microsoft's HLSL.
Except that I'm willing to bet that Microsoft isn't going to write a GLSL compiler for the X-Box 2.bloodbob said:How is Cg more portable? GLSL is completely platform independant as far as I know
1. Anybody can write their own back-end to the compiler.the Cg compiler currently only has profiles for NV_shaders,ARB assemble and the PS/VS assembly? So if you hardware can't run any of them your stuffed. Exactly which profile is Cg supposed to use for PS3?
I'm also betting they aren't gonna write a Cg Compiler back end either.Chalnoth said:Except that I'm willing to bet that Microsoft isn't going to write a GLSL compiler for the X-Box 2.bloodbob said:How is Cg more portable? GLSL is completely platform independant as far as I know
they just use the one supplied by sony?the Cg compiler currently only has profiles for NV_shaders,ARB assemble and the PS/VS assembly? So if you hardware can't run any of them your stuffed. Exactly which profile is Cg supposed to use for PS3?
1. Anybody can write their own back-end to the compiler.
So your suggesting the developers start writing the back-ends or would
And that makes it MORE portable how? Its gonna make it less portable.2. Since nVidia's developing a GPU for use in the PS3, you can bet that they'll also develop an appropriate target.
Does that include the emotion engine on the PS2?3. Cg currently supports targets for all assembly-language pixel/vertex shaders out there, except for ATI's proprietary R200 pixel shader and PS 1.4 in Direct3D.
They didn't for Windows, either; it's not necessary. The compiler can be included in a DLL or in the executable shipped with the game. The shader gets compiled by Cg into DirectX assembler shader code and tossed to the API.bloodbob said:I'm also betting they aren't gonna write a Cg Compiler back end either.Chalnoth said:Except that I'm willing to bet that Microsoft isn't going to write a GLSL compiler for the X-Box 2.bloodbob said:How is Cg more portable? GLSL is completely platform independant as far as I know
Hows that any better then Just tossing shader code directly into an API? your just adding an additional layer and potentially removing higher level optimisations.Ostsol said:They didn't for Windows, either; it's not necessary. The compiler can be included in a DLL or in the executable shipped with the game. The shader gets compiled by Cg into DirectX assembler shader code and tossed to the API.
A) When it is out -- or actually, when the SDK is out, it is possible that NVidia will write a backend for Cg to support whatever shader spec the XBox 2 supports.bloodbob said:Umm A) the XBOX-2 isn't even out yet B) How does that any better then Just tossing shader code directly into an API?Ostsol said:They didn't for Windows, either; it's not necessary. The compiler can be included in a DLL or in the executable shipped with the game. The shader gets compiled by Cg into DirectX assembler shader code and tossed to the API.
A) When it is out -- or actually, when the SDK is out, it is possible that ATI will write a backend for GLSL to support whatever shader spec the XBox 2 supports.Ostsol said:A) When it is out -- or actually, when the SDK is out, it is possible that NVidia will write a backend for Cg to support whatever shader spec the XBox 2 supports.bloodbob said:Umm A) the XBOX-2 isn't even out yet B) How does that any better then Just tossing shader code directly into an API?Ostsol said:They didn't for Windows, either; it's not necessary. The compiler can be included in a DLL or in the executable shipped with the game. The shader gets compiled by Cg into DirectX assembler shader code and tossed to the API.
B) Well, it is true that one could simply ship pre-compiled ASM with the game. Either way, it originally came from Cg. Chalnoth's point, as I see it, is that with GLSL you don't get either option since the existing compilers map directly to the internal instruction codes used by the hardware.
Wrong. Cg works in Windows because it compiles down to existing low-level shader languages. It is a layer separate from the API and the display drivers.bloodbob said:Microsoft didn't write a GLSL for windows either yet it clearly works for both ATI and NV. Well okay I guess you could say you don't need drivers for Cg to work on windows but of course thats only true because microsoft wrote a reference render.