POV-Ray : Newsgroups : povray.general : How to make a smooth lathe object : Re: How to make a smooth lathe object Server Time
8 Jul 2024 12:09:45 EDT (-0400)
  Re: How to make a smooth lathe object  
From: William F Pokorny
Date: 31 May 2014 08:06:24
Message: <5389c5c0$1@news.povray.org>
On 05/29/2014 12:02 PM, xslittlegrass wrote:
> Hi Le,
>
> Thanks for your reply, that's very helpful.
> But do you know how to smooth a 2d data set so that it is G4 continuity ?
>
> Best,
> xslittlegrass
>
I've no easy answer to your question. Perhaps you could use the points 
as input to some form of catmull-rom spline, but most probably the 
result would still not be exactly the curve you want.

Maybe give inkscape (www.inkscape.org) a try. It has an option to draw 
Bezier curves/splines which can be saved to a file as POV-Ray prisms. 
Images can be imported and used as guides as you draw. The spline 
specification in each POV-Ray prism can be used directly with POV-Ray's 
lathe object. Best is that with a program like inkscape you can see your 
curve as you make adjustments.

In Inkscape, after drawing your initial Bezier curve, you can go to an 
"edit paths by points" mode, select sets of points on the curve by 
shift-picking on the points. With the points selected you can then use 
commands at the top like "Make selected nodes smooth" and "Make selected 
nodes auto-smooth" to keep particular points in line so to speak.

When working in POV-Ray's SDL I've found it easiest to use Bezier 
splines which are made up of sets of 4 vertices/points, two end points 
and two internal control points. Larger curves can be made by 
overlapping end points and smoothness at any overlapping end point is 
accomplished by matching the slopes of the nearest two control points to 
the overlapped points.

There are other interactive tools about for creating lathe and prism 
splines including one mentioned currently on the main povray.org web 
site called Epspline, though I have not used that one myself.

Bill P.


Post a reply to this message

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