POV-Ray : Newsgroups : povray.general : Most efficient way to code a hemisphere (lathe.inc) : Re: Most efficient way to code a hemisphere (lathe.inc) Server Time
29 Jul 2024 14:17:11 EDT (-0400)
  Re: Most efficient way to code a hemisphere (lathe.inc)  
From: Alain
Date: 28 Feb 2011 16:15:22
Message: <4d6c106a@news.povray.org>

> On second thought, my real goal is to have two different mesh2's, in this case
> created by Ingo's macros,  to have a perfectly smooth transition between them.
> As you point out it ultimately becomes a question of splines.
>
> Q: What is the most simplistic way to guarantee that two splines will have a
> perfectly smooth transition, say one defined  A to B, and another B to C?
>
> That is, If I have the "extra point" in a quadratic spline overlap, or the "two
> extra points" in a cubic_spline overlap?  Or again, would one have to "hard
> code" them as in the example of the trig functions for spheres.
>
>
>
>

The end point of the firts spline must coincide with the first point of 
the second one. The last control point of the first spline must coinside 
with the secont point of the second spline. The first control point of 
the second spline must coinside with the second to last point of the 
first spline.

That way, the slope and curvature will continue smoothly across the seam.

For the spline to closely follow the path of a circle, you need to 
increase the number of points. You can place them evenly at constant 
angle using sin and cos.
You'll probably need at least 10 points in a quarter circle, plus the 
control points.



Alain


Post a reply to this message

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