R300 vertex shader

RoOoBo

Regular
Where could I found information about the vertex shader (instructions, parameters, registers) of the R300?

The NVidia document about the NV30 new OpenGL extensions has most of the information for the NV30 vertex shader programs, but I can't find the same info for R300. It seems there isn't a specification for a new OpenGL extension for R300 vertex shader (and ARB_vertex_program doesn't cover branching).

For the R300 I just have the Siggraph docs that cover the pixel shader.

And about something different, I can't seem to find how current GPUs support clipping in hardware. In some references it talks about guard band clipping and the use of homogenous rasterization (Olano, Greer) to perform the clipping in the rasterization stage. This would mean that there wouldn't be any clipping operation in the geometry part of the pipeline, and therefore no primitive (triangle) operations would be performed in that part. But I'm not sure if they implement some kind of trivial rejection clipping (full primitives out of the guard-band or clip space) as what is explained in Foley & van Dam chapter 18.
 
RoOoBo said:
And about something different, I can't seem to find how current GPUs support clipping in hardware. In some references it talks about guard band clipping and the use of homogenous rasterization (Olano, Greer) to perform the clipping in the rasterization stage. This would mean that there wouldn't be any clipping operation in the geometry part of the pipeline, and therefore no primitive (triangle) operations would be performed in that part. But I'm not sure if they implement some kind of trivial rejection clipping (full primitives out of the guard-band or clip space) as what is explained in Foley & van Dam chapter 18.

apropos, if they did primitive rejection in clip space they'd still need consider primitive (i.e. connectivity) information in the transform pipeline.

i.e. if the transofrm pipe did not care about primitives (and all clipping/rejection was done later w/ guardband/screenspace clipping/homogeneous scanconversion) then it could not reject primitives either.
 
Well, to tell u the truth, if you're looking for the same extent of info nVidia provided about NV30 (OpenGL specs, etc...), you just ain't gonna find it... :(
 
http://oss.sgi.com/projects/ogl-sample/registry/

And check for ARB_vertex_program and also ARB_fragment_program. The first is supported on the latest 9700 drivers.

As for clipping... I think most cards have a HUGE (32bit in pixels) guardband and mostly only have to do near plane clipping. Clipping is done in clip (NDC) space. I'm not sure about back face culling. I do it in screen space by testing the signed area of the triangle, but you could potentially do it earlier than that.
 
fresh said:
As for clipping... I think most cards have a HUGE (32bit in pixels) guardband and mostly only have to do near plane clipping. Clipping is done in clip (NDC) space. I'm not sure about back face culling. I do it in screen space by testing the signed area of the triangle, but you could potentially do it earlier than that.

actually you're a bit optimisic re guardband - most cards have a couple of thousands of units of guardband. and btw, clip space is not NDC space - clip-space is the one before the perspective division. this way clipping remains all nicely linear; NDC is past the p. division, if you clipped in NDC you'd have to 'inverse-project' all those quantities which are hyperbolic after perspective division, i.e. everything except the vertex spatial coords.

edit: come to think of it, fresh, you don't have to inverse-project those quantities - linear interpolation of the inverses would still work (of course), with the only implication that you may get singularities. but anyhow, clip space is called what you get after the perspective transform, just before the perspecive division.
 
MDolenc said:
Actually GeForce cards have 1*10^8 guardband. But I guess it depends on what you took for "most cards"...

indeed. i never looked at the nv10+ guardband caps. seems they either take floating-point or real large fixed-point scr coords (27 bits or so for the whole part). oth, there are still devices with (reported) guardband of 0 (e.g the matrox gxxx series).
 
Back
Top