29
Jul
06

…a slight non-Euclidean curvature

This is brilliant.

In other news, I’ve been thinking about curvature lately. Remember a few weeks ago, when I wrote about multiresolution meshes? I mentioned that level-of-detail (LOD) people are trying to cover the screen in pixel-sized triangles, and that I don’t think video cards are really powerful enough to do that at satisfying resolutions (say, 1920×1200) and seamless frame rates (60 Hz).

Even if they are, so what? If you can save a few thousand triangles per frame without creating a new bottleneck, I can put those triangles to good use.

That said, the idea of drawing pixel-sized (give or take) triangles is pretty elegant in terms of sampling: you’re basically sampling at the pixel-level anyway (well, if you’ve turned on hardware antialiasing, you’re sampling at two, four, eight, or whatever times the pixel resolution, then averaging; still, at some point you’re taking point samples on a regular rectangular grid, which is the point I’m trying to make). Drawing pixel-sized tris is about as good as you can get.

A few interesting things fall out of this:

  1. You can’t faithfully sample geometry with a higher frequency than your frame buffer’s Nyquist limit. Really — I’ve tried it. (I drew a heightfield terrain model with subpixel-sized tris.) You get sparkles in the undersampled geometry as different triangles on the same pixel “win” the Z-buffer test.So drawing geometry at full resolution all the time is actually a bad idea, even if you have sufficiently powerful enough hardware to do so.The “frequency” of your geometry, unfortunately, isn’t constant. It changes as the model gets further away from the viewpoint, covering fewer pixels.
  2. When you draw (read: “sample”) a mesh, you’re actually sampling it twice: first when you figure out which triangles to draw, and again when you rasterize those triangles into pixels. The relationship between these two sampling steps is what makes multiresolution rendering interesting.
  3. Parts of the model with low-frequency information don’t need to be sampled at the same rate as high-frequency parts — if you have a good way to reconstruct the low-frequency information. The problem is, for the most part we don’t have a particularly efficient way to reconstruct the low-frequency mesh. All we have are triangles — which are inconveniently flat.Suppose you have a model of a sphere. There’s not a hell of a lot of information involved there — just a centre and a radius, basically. Low-frequency. On the other hand, to render that sphere — with triangles — at a reasonable level of fidelity (to the point where it actually looks like a sphere, rather than a faceted approximation), you need to sample it fairly densely.
  4. In some parts of the science-and-engineering world, you run into the idea of importance sampling. It’s pretty intuitive: sample more where the signal is more interesting. Well, we can’t do much about the distribution of samples on the monitor, but we can do quite a bit about the distribution of triangles on the mesh.

All of these factors suggest that multiresolution rendering is a pretty cool problem.

So where does curvature come in? Curvature — in particular, negative curvature — is an important perceptual clue for humans (and humans are the ones buying video games and reviewing grant proposals), along with a few other things like silhouette and shadow. Well, I have a few tricks for dealing with silhouette, and shadow is essentially silhouette — from the point of view of the light source. Now I want to do something about curvature.


0 Responses to “…a slight non-Euclidean curvature”



  1. No Comments Yet

Leave a Reply




anarchocapitalist agitprop

Be advised

I say fuck a lot
Grammar Nazi

Categories

Archives

Statistics FTW