PDA

View Full Version : Sharing some knowledge



Bart
10-12-2007, 05:40 AM
Greetings everyone,

I have found this forum very helpful many times in finding answers regarding several graphics projects. This being my first post on this forum, I first wanted to say thanks to all the people that are helpful and give decent answers (well... at least most of the time).

As a student I have been working on a project benchmarking several new possibilities of GPUs, e.g. vertex texturing vs normal texturing, data-dependent flow-control statements vs hard-coded flow-control statements, etc (my first experience with GPU programming). I'm not very fond of the thought that my work is only read and (hopefully) used by my teacher, so I also wanted it to share with you people:

http://bars.rug.nl/download/bd7f8c15d967b0f4

All comments and advice is welcome, though I can't promise to process them all.


Besides these benchmarks, I also wrote a paper regarding the architecture of graphics cards. This paper covers topics as the 3D-graphics pipeline, texture mapping (bilinear, trilinear, anisotropic filtering, etc), antialiasing (super- and multi-sampling), PCI Express, Multi-GPU, etc. For some (perhaps most) of you, this is rather familiar, but browsing this forum I often encountered questions that were related to this. So, if someone wants to have it, just give a yell and I'll post a link to this paper as well.

Nicolai de Haan Brøgger
10-12-2007, 06:29 AM
Hi Bart and thanks for the paper - nice reading. I just wanted to ask if you have done some benchmarking on vertex texture fetch using other texture formats than GL_LUMINANCE_FLOAT_32 and GL_RGBA_FLOAT_32 on the 8800 GTX?

kind regards,
Nicolai de Haan Brøgger

sqrt[-1]
10-12-2007, 08:12 AM
I would have liked to see alpha testing in the "Rejecting fragments" section.
(It has always been some question if alpha testing is faster than discard)

Bart
10-12-2007, 04:39 PM
@Nicolai de Haan Brøgger: no, not on the 8800 GTX. I did try other formats on the 6200 (which I primarily used for writing the shader programs). And indeed, it took forever.... it took so long that I had abort the application manually. I think, you will see this same performance drop on the 88000 GTX, because as far as I know, the 8800 GTX doesn't support more formats than the 6200.

@sqrt[-1]: that's a good idea. I'll see if I can also test that. It shouldn't be too hard to implement it.

Zengar
10-12-2007, 05:26 PM
Originally posted by Bart:
I think, you will see this same performance drop on the 88000 GTX, because as far as I know, the 8800 GTX doesn't support more formats than the 6200.
Very unlikely. G80 runs all shader types on the same hardware, so texturing capabilities should be the same regardless of vertex or fragment shaders.

Bart
10-13-2007, 10:44 AM
Originally posted by Zengar:

Originally posted by Bart:
I think, you will see this same performance drop on the 88000 GTX, because as far as I know, the 8800 GTX doesn't support more formats than the 6200.
Very unlikely. G80 runs all shader types on the same hardware, so texturing capabilities should be the same regardless of vertex or fragment shaders. You might be right about the 8800 GTX supporting more formats, because of the new architecture of the G80.

Though I don't think texturing capabilities are the same for both vertex and fragment programs. For example, vertex texture fetches do not automatically compute the level of detail (used with mipmapping). With fragment programs, the level of detail is measured as how magnified or minified the texture image is on the screen. And it is computed based on the rate of change of the texture coordinates from pixel to pixel. Since vertex textures are only accessed at the vertices, the hardware would have to compute this value in a different way compared to fragment textures. Therefore, the only way to compute this value at vertex level (currently), is to make an own implementation for computing the level of detail in the vertex program.

Zengar
10-13-2007, 12:17 PM
I just assume that you have to specify the LOD manually. I wanted to say that G80 should support same texture formats for all of the shader types.