POV-Ray : Newsgroups : povray.binaries.images : Documentation review requested Server Time
7 Nov 2024 11:34:55 EST (-0500)
  Documentation review requested (Message 1 to 2 of 2)  
From: Cousin Ricky
Subject: Documentation review requested
Date: 4 Sep 2015 09:23:56
Message: <55e99b6c$1@news.povray.org>
I have written a macro to facilitate the creation of Bézier curves.  It 
will be included in the SphereSweep module in the Object Collection. 
Below is the proposed text of its documentation, with an accompanying 
illustration.  I would appreciate feedback on how clearly it explains 
the macro.

Due to a glitch in the NNTP-to-HTTP conversion, you may see some funny 
characters in the word "Bézier" if you are using the Web view.  They are 
supposed to be an e with an acute accent.  Don't worry about those; they 
will appear correctly in the user manual (unless you are using an 
obsolete Web browser that doesn't understand the HTML 5 character 
encoding directive).
_________________________________________________

Macro SSwp_Bezier (v_Ctrls, s_File, VDim, Places)

   As a convenience for facilitating continuity between Bézier spline
   segments, this macro accepts a set of points and vectors, and
   converts them to an array of Bézier control points. The returned
   array may be passed directly to a SphereSweep object macro; or its
   elements may be used to construct a lathe or prism primitive.
   Optionally, the points may be written to a file.

   The set of points and vectors is an n x 3 array, where n is the
   number of distinct points through which the spline passes. (For this
   array, the last point of a Bézier segment and the first point of the
   next segment are considered to be the same point.) Each element
   [][1] is a point through which the spline passes. Elements [][0] and
   [][2] are vectors pointing to the previous and next intermediate
   control points, respectively, in the spline. (The spline does not
   typically pass through the intermediate control points.) By making
   these vectors collinear, while pointing in opposite directions,
   smooth transitions may be maintained between spline segments.

   Elements [0][0] and [n - 1][2] are ignored.

   The illustration shows an example of how this array translates to
   the final set of control points.

Arguments

   v_Ctrls:
     The array of points and vectors. This argument is input only and
     is not altered.
   s_File:
     The name of a file to which to write the output array. Use "-"
     (hyphen) to write to the debug stream or "" (the null string) for
     no written output.
   VDim:
     The dimension size of the points to be written to the file
   Places:
     The number of decimal places to be written


Post a reply to this message


Attachments:
Download 'spheresweep_bezier.png' (21 KB)

Preview of image 'spheresweep_bezier.png'
spheresweep_bezier.png


 

From: Thomas de Groot
Subject: Re: Documentation review requested
Date: 5 Sep 2015 03:27:11
Message: <55ea994f$1@news.povray.org>
It seems clear enough to me. I do not know what you intend to do with 
the two sentences put between parentheses. If you intend to keep them 
'as is' then delete the parentheses. I do not think you want to take out 
the sentences themselves: they give important information.
-- 
Thomas


Post a reply to this message

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