Descriptions and Examples for the POV-Ray Raytracer by Friedrich A. Lohmüller Geometric Shapes in POV-Ray Italiano Français Deutsch

Home
- POV-Ray Tutorial

Geometric Shapes
Index
Basic Shapes
> sphere
- cylinder
- cone
- torus
- box
- prism
- plane
- sor
- lathe
- superellipsoid
- ovus

Shapes by macro + CSG
Shapes in "shapes3.inc"
Other Shapes by macros
3D text shapes
other Shapes
Non CSG Shapes
height_field + HF macros
Isosurfaces

# sphere = ellipsoid, ball

sphere
general syntax:
 ```sphere{ , r texture{ ... ... } }```
In this case <xM,yM,zM> are the coordinates of the center and r is the radius.
The examples here:
 ```sphere{< 0,0, 0>,1.0 texture{...}} sphere{<-1,2,-3>,1.0 texture{...}} sphere{< 2,3, 5>,1.0 texture{...}}```
 If a sphere has to be deformed by "scale< , , >" to a ellipsoid, it's recommanded to do this according to the following principle of construction: 1st step: Deforming the shape at the origin of the coordinates "<0,0,0>" by "scale< , , >" and then 2nd step: Moving the shape to it's final position in the world by "translate< , , >". Because the "scale< , , >" works always relative to the center "<0,0,0>" it's recommanded to do it before translating!.
sphere + scale<...> = ellipsoid
general syntax:
 ```sphere{ , r scale texture{ ... ... } }```
Here <xM,yM,zM> are the center coordinates, r is the radius and
sx,sy,sz are scale factors in x-, y- and z-direction.
Examples here:
 ```sphere{<0,0,0>,1.0 scale<2,0.4,1> translate< 0,0, 0> texture{...}} sphere{<0,0,0>,1.0 scale<1,1,2> translate<-1,2,-3> texture{...}} sphere{<0,0,0>,1.0 scale<1,1,0.2> translate< 2,3, 5> texture{...}}```

 © Friedrich A. Lohmüller, 2013 www.f-lohmueller.de top