## Rounded edges ?

### Rounded edges ?

Is it possible to make a cylinder with rounded edges using the primatives
(CGS)?

Thanks

Ken

### Rounded edges ?

Quote:>Is it possible to make a cylinder with rounded edges using the primatives
>(CGS)?

well, not necisarily with CGS, but if you just make a 1 component blob
with a cylinder, the ends will curve.

blob
{
threshold 0.3
cylinder  { <0,0,0>, <0,5,0>, 1, 1
texture { pigment { color rgb <1,1,0> } }
}

Quote:}

light_source { <0,10,10> color rgb <1,1,1> }
camera { location <0,10,10> look_at <0,2,0> }

Try that =D

### Rounded edges ?

: Is it possible to make a cylinder with rounded edges using the primatives
: (CGS)?

I think you can use a superellipsoid for that, but otherwise you can use a
two cylinders and two torii, using the torii to round off the ends of the
cylinder, and the other cylinder to fill in the centers of the torii.

--
Mario Becroft                        Auckland, New Zealand

Tariland, Atari Support in New Zealand                        _.|o o  |_   ) )

### Rounded edges ?

> Is it possible to make a cylinder with rounded edges using the primatives
> (CGS)?

Yes, you could easily use two cylinders (one short & fat, one tall and
thin), and two torii.  However, POVRay 3.x provides a primitive that is
already a rounded cylinder - the superellipsoid, eg:

superellipsoid {<1, .5> rotate x * 90}

This will give a rounded cylinder centred on the origin (measuring
2x2x2), lying along the y-axis.  To change the amount of roundedness,
change the .5 in the superellipsoid vector (smaller numbers mean less
curvature, larger numbers means more curvature).  Changing the first
number will change the shape of the object itself; numbers smaller than
1 give a rounded box, 2 gives a box with sharp edges along the y-axis,
numbers larger than 2 give a curved diamond type shape.  Used in
combination you can create all sorts of objects; try <1, 3> for a
spinning top, or <3, 3> for a curved 3D star.

### Rounded edges ?

Quote:> Is it possible to make a cylinder with rounded edges using the primatives
> (CGS)?

> Thanks

> Ken

This is how I do cylinders with rounded edges, where C is the size of the
edge:

merge {
torus <1-C,C rotate 90*x translate C*z>
cylinder <C,(1-C)*z,1>
cylinder <0,z,1-C>
torus <1-C,C rotate 90*x translate (1-C)*z>

Quote:}

This creates a rounded edge cylinder along the z axis.  You could also use
a superellipsoid, but I find them difficult to get right size and they
don't render any faster than the example above.

Steven

### Rounded edges ?

If you're using POV-Ray
#declare Rounded_Box = superellipsoid { <r, r> }
#declare Rounded_Cylinder = superellipsoid { <1.0, r> }
These examples are from the POV docs.

### Rounded edges ?

This has already been answered more than once but in case you missed it you
can create such a rounded cylinder easily by use of "union" or "merge" with
a cylinder object and a squashed sphere, torus, or a blob depending on what
kind of effect you want to create.

The BETTER solution (taken direct from the POV-Ray docs) is:

The superquadric ellipsoid is an extension of the quadric ellipsoid. It can
be used to create boxes and cylinders with round edges and other
interesting shapes. Mathematically it is given by the equation:

f(x, y, z) = (|x|^(2/e) + |y|^(2/e)) ^ (e/n) + |z|^(2/n) - 1 = 0

The values of e and n, called the east-west and north-south exponent,
determine the shape of the superquadric ellipsoid. Both have to be greater
than zero. The sphere is e. g. given by e = 1 and n = 1.

The syntax of the superquadric ellipsoid, which is located at the origin,
is:

superellipsoid { <e, n> }

Two useful objects are the rounded box and the rounded cylinder. These are
declared in the following way.

#declare Rounded_Box = superellipsoid { <r, r> }
#declare Rounded_Cylinder = superellipsoid { <1, r> }

The roundedness r determines the roundedness of the edges and has to be
greater than zero and smaller than one. The smaller you choose the values
of r the smaller and sharper the edges will get.

Very small values of e and n might cause problems with the root solver (the
Sturmian root solver cannot be used).

--
Best regards,
_ __                      _    ,   _ _ _
' )  )     /         _/_  ' )  /   ' ) ) )
/--' ____/___/> __  /     /--/     / / / __,_  __  o _   ______
/  \_(_) /_) (__/ (_<__   /  ( o   / ' (_(_) (_/ (_<_/_)_(_) / <_

Robert H. Morrison                      Tel:   +49 721 9628 167
Software Development, Basis Team        FAX:   +49 721 9628 261

Quote:> Is it possible to make a cylinder with rounded edges using the primatives
> (CGS)?

### Rounded edges ?

Quote:> The superquadric ellipsoid is an extension of the quadric ellipsoid. It
can
> be used to create boxes and cylinders with round edges and other
> interesting shapes.  <etc>

I am interested in making some basic rounded polygons for use in rendered
patchwork quilts. I need triangles and rectangles for sure, but arbitrary
polygons would be nice.

I'm trying for the look of an actual quilt, where there are soft
indentations at the seams (edges).  Can I make soft triangles with
superquadratics? Or should I be investigating csg, blobs, height fields?

Does anybody have any ideas?  Thanks in advance.

Sally

### Rounded edges ?

I think I would recommend using blobs or a heightfield.  You couldn't
really do anything but cylinders and cubes with superquadratic
ellipsoids, and you would also end up with very deep seams between each
patch.  With blobs, you can get the effect of one piece of fabric since
it will flow from patch to patch.  A heightfield might be easiest
because you can just draw out your quilt in a paint program (two images,
one for the height-field, and one for the image map), but I don't know
what the quality would be like.  It might be kind of tricky to get
smoothely rounded edges on each piece.

Ken

> > The superquadric ellipsoid is an extension of the quadric ellipsoid.
> It
> can
> > be used to create boxes and cylinders with round edges and other
> > interesting shapes.  <etc>

> I am interested in making some basic rounded polygons for use in
> rendered
> patchwork quilts. I need triangles and rectangles for sure, but
> arbitrary
> polygons would be nice.

> I'm trying for the look of an actual quilt, where there are soft
> indentations at the seams (edges).  Can I make soft triangles with
> superquadratics? Or should I be investigating csg, blobs, height
> fields?

> Does anybody have any ideas?  Thanks in advance.

> Sally

### Rounded edges ?

>I'm trying for the look of an actual quilt, where there are soft
>indentations at the seams (edges).  Can I make soft triangles with
>superquadratics? Or should I be investigating csg, blobs, height fields?

>Does anybody have any ideas?  Thanks in advance.

How about using POVs built-in quilted pattern? It is described in
section 7.6.7.16 of the docfile.

/Ib

I've tried using it with various settings, but the results are always odd.
I've included an attachment showing the result of the plugin applied to a
box.
Do I have to use the plugin on each ploy separately or something?

Thanks for any help.