|
|
Am 29.07.2010 11:03, schrieb tgl:
> Could some understanding person out there please show
> how they would code a sphere_sweep b_spline of a 180
> degree circular arc into POV.
> And...How would the above arc be coded as a sphere_
> sweep natural_spline?
Both b_spline and natural_spline are actually cubic splines at their
heart (with different approaches of parameterizing the spline via the
control points). Unfortunately, unless I'm totally mistaken, cubic
splines are incapable of representing circular arcs, so the best you can
get is an approximation.
Post a reply to this message
|
|
|
|
tgl wrote:
> Hello group
> Could some understanding person out there please show
> how they would code a sphere_sweep b_spline of a 180
> degree circular arc into POV.
> And...How would the above arc be coded as a sphere_
> sweep natural_spline?
> Thank you.
>
>
camera {
location <0,0,-50>
look_at <0.0, 0.0, 0.0>
right x*image_width/image_height
}
// create a regular point light source
light_source {
0*x // light's position (translated below)
color rgb <1,1,1> // light's color
translate vrotate(<0,0,-100>,<60,60,0>)
}
sphere { 0, .5 pigment {rgb y}}
cylinder { <-30,0,0>,<30,0,0>,.25 pigment{rgb y}}
// create a curved tube object translating a sphere along a certain path
//object {
sphere_sweep {
cubic_spline
21,
#local I=-1;#while(I<20)
vrotate (<20,0,0>,<0,0,I*10>), .5
#local I=I+1;#end
pigment{rgb x}
}
Post a reply to this message
|
|