POV-Ray : Newsgroups : povray.general : Not-so-smooth height_field in POV 3.1 : Re: Not-so-smooth height_field in POV 3.1 Server Time
11 Aug 2024 17:20:34 EDT (-0400)
  Re: Not-so-smooth height_field in POV 3.1  
From: Lummox JR
Date: 7 Jun 1999 13:38:13
Message: <375C0403.257B@aol.com>
Bob wrote:
> 
> Heightfields can be made to have no pixelization appear unless the camera
> is right near the surface. I gather this is what you are doing though and
> of course you would always see the individual "squares" if the camera
> either zooms in or is real close no matter what the original resolution
> was. Seems a problem of proximity if anything. Basically what you describe
> you want to use is further refinement of the resolution or a enhanced
> tesselation, ie. more division of the pixels, or more correctly the
> vertexes. Since these would originally be flat squares I'm guessing the
> production of a HF creates triangles having these as vertex points
> instead; meaning a image used to make the HF, if black and white pixels in
> a checkerboard pattern, would become a HF of as many peaks and valleys as
> there are pixels. So it is feasible I would suppose to subdivide what
> exists in some sort of interpolation manner.

Yes, the camera is indeed close to the surface. The height field extends
actually a little above the camera, so that the camera is within the
field itself. This is necessary to create the sand dune effect I want.
Even so, it's not proximity that's the *heart* of the problem (though it
is bringing it out, so to speak), but rather the renderer's poor
smoothing options.
The resolution of the height field, as I mentioned before, really isn't
the problem. Going to a larger height field with more resolution only
makes those checkerboard reflective spots smaller, but it by no means
eliminates them. Ideally, if the renderer would itself interpolate the
pixels according to a quadratic function or some such, instead of
relying on a larger height field, I suspect the problem would solve
itself. Using such a method, triangles wouldn't even be needed at all;
the surface itself would be dynamic and rounded.
Low bit depth of the height field was a problem in some early images,
but 12 bits or more per pixel takes care of that; and I'm using 16 now.

Since it seems the simplest way for the renderer to draw a height field
is to produce those triangles, I guess we're stuck with them until some
better option comes along. But as long as we have to live with the
triangles, there needs to be some way of solving this proximity problem.
Those checkerboard reflection patterns *can* be smoothed out with simply
a more aggressive smoothing algorithm, one that can be made to produce
more rounded-looking surfaces, or flatter.
No other type of object I know of will produce the dune effect I want,
or else I'd try it; I may be an algebraphile, but I shudder at the
thought of producing a 7th-order polynomial to fit the bill. Plus, I've
already positioned the other objects within the scene--replacing the
height field at this late date would bring on problems innumerable.

Lummox JR


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.