POV-Ray : Newsgroups : povray.general : rounded_objects: a new feature? : Re: rounded_objects: a new feature? Server Time
3 May 2024 05:27:43 EDT (-0400)
  Re: rounded_objects: a new feature?  
From: John Greenwood
Date: 15 Sep 2016 13:10:00
Message: <web.57dad3c8696ad3a7cafab50@news.povray.org>
scott <sco### [at] scottcom> wrote:

> It actually sounds similar to distance field rendering which is used a
> lot in real-time raytracing. Once you have the distance fields then it's
> easy to do a "smooth union" between shapes:
>
> http://www.iquilezles.org/www/articles/smin/smin.htm

Alain wrote:
> You may do a blobbing of the intersection of four planes to get a
> rounded tetrahedron, of six planes for a rounded box,...
> Possible, done before and relatively slow.

I think this means that what I am suggesting is feasible, and indeed already
do-able to a limited extent.

However both the blob definition and isosurfaces are for me non-intuitve.

Take the tetrahedron for example, I will probably know where I want the four
vertices to be, so defining each of the four rounded_object plane elements with
three vectors is simple. Writing it as a set of equasions needs a bit of
pondering, which is what computers are for.

I can see how blob definition has been written in its simplest form by
programmers, but for the user it would be much more convenient to input the
radius of the sphere that would be seen in isolation and the distance the field
extends beyond this. I know these relate to the actual input parameters by very
simple arithmetic, which is also is what computers are for.

Of course calculating field strengths is going to slow things down, but would it
be possible to be able to have a fast mode where this left out and the object
rendered with sharp corners?

I think implementing rounded-object with just planes, cylinders and spheres
would not be that difficult and would give:
- an immediate improvement in usability.
- Individual radii for planes would enable a significant new repertoire of
rounded shapes.
- Rounded objects as elements would extend this
- sphere sweep elements would be amazing.

scott <sco### [at] scottcom> wrote:

> Note that there are two distinct types of "round" being discussed, it's
> important not to confuse them. The first is the "CAD" type of perfect
> round that is formed by conceptually rolling a sphere (of radius equal
> to the round you want) along the edge. The second is this type of
> "artistic" round that smoothly blends the two shapes, but is not
> necessarily possible to accurately specify the round radius (or it might
> not even be constant throughout the round).

My point exactly when I wrote:

> >(The calculation might be faster with cubic; the corners would not be exactly
> > circular, but would anyone notice or care?)

Maybe we could go further and, with an extra optional parameter, change the
profile of the rounding from a rounded bevel to a "V" shape?


Post a reply to this message

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