Difference between revisions of "User:Le Forgeron/polyline"
Jump to navigation
Jump to search
Le Forgeron (talk | contribs) |
Le Forgeron (talk | contribs) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | = Polyline = | + | {{User:Le_Forgeron/HgPovray38/available}} |
+ | |||
+ | == Polyline == | ||
Similar to polygon, but using the absolute value of the winding number instead of odd-even filling. | Similar to polygon, but using the absolute value of the winding number instead of odd-even filling. | ||
− | == Syntax == | + | === Syntax === |
<source lang="txt"> | <source lang="txt"> | ||
Line 12: | Line 14: | ||
</source> | </source> | ||
− | == Winding number == | + | === Winding number === |
+ | |||
+ | Only the absolute number is considered (the notions of clockwise & anti-clockwise vary with the orientation of the system). | ||
[[Image:LeForgeronPolyline.png|"winding number"]] | [[Image:LeForgeronPolyline.png|"winding number"]] |
Latest revision as of 11:34, 24 June 2018
- Everything about HgPovray38 in User:Le_Forgeron/HgPovray38
- Code is available on branch hgpovray38 at https://github.com/LeForgeron/povray
Polyline
Similar to polygon, but using the absolute value of the winding number instead of odd-even filling.
Syntax
polyline { \(Px [,]\)\{3,n\} range { \(<low,high>\)\{1,m\} } OBJECT_MODIFIERS }
n coplanars points Px
<low,high> specification of interval for winding number
Winding number
Only the absolute number is considered (the notions of clockwise & anti-clockwise vary with the orientation of the system).
#declare A=<0,3,0>;
#declare B=<6,3,0>;
#declare C=<4.5,1,0>;
#declare D=<7,2,0>;
#declare E=<4.5,6,0>;
#declare F=<7,4,0>;
#declare G=<2,4,0>;
#declare H=<4,6,0>;
#declare I=<4,0,0>;
#declare J=<5,0,0>;
#declare K=<5,8,0>;
polyline
{
A, B, C, D,
E, F, G, H,
I, J, K, A
range { 2 }
texture { pigment { color srgb 0.5 }}
}
polyline
{
A, B, C, D,
E, F, G, H,
I, J, K, A
range { 1 }
texture { pigment { color srgb 0.75 }}
}