D3D Pixel/Vertex shader discussion (for shader model 2.0+)

Jason Green jave27 at gmail.com
Thu May 4 20:46:58 CDT 2006


On 5/4/06, Raphael <fenix at club-internet.fr> wrote:
> Only one "technical thing", how you expect to determin if you need GLSL or if
> ARB_vertex/ARG_fragment is suffcient ?
>   1 - always use GLSL when available, else try ARB compat code ?
>   2 - try to use ARB when possible, else switch to GLSL ?
>   3 - choose the more performant (heuristic depency of opcodes performances) ?

In general, any shader version 2.0 or higher will require GLSL.  There
are exceptions, but that's the general rule of thumb.  So, unless the
performance is seriously impacted, we should use GLSL if possible. 
Also, I'm not sure of the ramifications of using both GLSL shaders and
ARB_vertex_program shaders at the same time...  Haven't got that far
yet, but it's a good question to look into.  Phil Costin has already
submitted a patch which is in Mike's tree which checks for the
existence of the ARB_shader_100 extension (whatever it's called) which
allows us to use GLSL shaders.

> And why about specifics NV/ATI extensions for shaders ?

Hopefully we won't need them for shaders as there is already an ARB_
extension that should be usable by both vendors.  But, if it turns out
that we do need one or the other, then it will have to be an if ()
else type of scenario.



More information about the wine-devel mailing list