|
|
In article <47cd1bc5$1@news.povray.org>, tim### [at] comcastnet says...
> Here's a macro that should work better.
>
> #macro Rounded_Octahedron(Major, Minor, MRG)
> #local Top = <0,Major,0>;
> #local Bot = <0,-Major,0>;
> #local LF = <-0.7071*Major,0,-0.7071*Major>;
> #local LR = <-0.7071*Major,0,0.7071*Major>;
> #local RF = <0.7071*Major,0,-0.7071*Major>;
> #local RR = <0.7071*Major,0,0.7071*Major>;
> #local A = 35.26413;
> #local B = vrotate(<0,0,-Minor>,<A,0,0>);
> #local C = vrotate(<-Minor,0,0>,<0,0,-A>);
> #local D = vrotate(<0,0,Minor>,<-A,0,0>);
> #local E = vrotate(<Minor,0,0>,<0,0,A>);
> #local B2 = <B.x,-B.y,B.z>;
> #local C2 = <C.x,-C.y,C.z>;
> #local D2 = <D.x,-D.y,D.z>;
> #local E2 = <E.x,-E.y,E.z>;
> #if (MRG) merge{ #else union{ #end
> mesh {
> // faces
> triangle {Top+B,RF+B,LF+B}
> triangle {Top+C,LF+C,LR+C}
> triangle {Top+D,LR+D,RR+D}
> triangle {Top+E,RR+E,RF+E}
> triangle {Bot+B2,RF+B2,LF+B2}
> triangle {Bot+C2,LF+C2,LR+C2}
> triangle {Bot+D2,LR+D2,RR+D2}
> triangle {Bot+E2,RR+E2,RF+E2}
> // peaks
> triangle {Top+B,Top+C,Top+D}
> triangle {Top+B,Top+E,Top+D}
> triangle {Bot+B2,Bot+C2,Bot+D2}
> triangle {Bot+B2,Bot+E2,Bot+D2}
> triangle {LF+B,LF+C,LF+C2}
> triangle {LF+B,LF+B2,LF+C2}
> triangle {LR+C,LR+D,LR+D2}
> triangle {LR+C,LR+C2,LR+D2}
> triangle {RF+B,RF+E,RF+E2}
> triangle {RF+B,RF+B2,RF+E2}
> triangle {RR+D,RR+E,RR+E2}
> triangle {RR+D,RR+D2,RR+E2}
> // edges
> triangle {LF+B,RF+B,RF+B2}
> triangle {LF+B,LF+B2,RF+B2}
> triangle {LF+C,LR+C,LR+C2}
> triangle {LF+C,LF+C2,LR+C2}
> triangle {LR+D,RR+D,RR+D2}
> triangle {LR+D,LR+D2,RR+D2}
> triangle {RF+E,RR+E,RR+E2}
> triangle {RF+E,RF+E2,RR+E2}
> triangle {Top+B,Top+C,LF+C}
> triangle {Top+B,LF +B,LF+C}
> triangle {Top+B,Top+E,RF+E}
> triangle {Top+B,RF +B,RF+E}
> triangle {Top+D,Top+C,LR+C}
> triangle {Top+D,LR +D,LR+C}
> triangle {Top+D,Top+E,RR+E}
> triangle {Top+D,RR +D,RR+E}
> triangle {Bot+B2,Bot+C2,LF+C2}
> triangle {Bot+B2,LF +B2,LF+C2}
> triangle {Bot+B2,Bot+E2,RF+E2}
> triangle {Bot+B2,RF +B2,RF+E2}
> triangle {Bot+D2,Bot+C2,LR+C2}
> triangle {Bot+D2,LR +D2,LR+C2}
> triangle {Bot+D2,Bot+E2,RR+E2}
> triangle {Bot+D2,RR +D2,RR+E2}
> inside_vector <0,Minor,0>
> }
> sphere {Top,Minor}
> sphere {Bot,Minor}
> sphere {LF,Minor}
> sphere {LR,Minor}
> sphere {RF,Minor}
> sphere {RR,Minor}
> cylinder{Top,LF,Minor}
> cylinder{Top,LR,Minor}
> cylinder{Top,RF,Minor}
> cylinder{Top,RR,Minor}
> cylinder{Bot,LF,Minor}
> cylinder{Bot,LR,Minor}
> cylinder{Bot,RF,Minor}
> cylinder{Bot,RR,Minor}
> cylinder{RF,RR ,Minor}
> cylinder{LF,LR ,Minor}
> cylinder{RF,LF ,Minor}
> cylinder{RR,LR ,Minor}
> }
> #end
>
Once I figured out what the bloody settings did, it works wonderfully.
Thanks. Now to just figure out how to do the rest of it... lol
--
void main () {
if version = "Vista" {
call slow_by_half();
call DRM_everything();
}
call functional_code();
}
else
call crash_windows();
}
<A HREF='http://www.daz3d.com/index.php?refid=16130551'>Get 3D Models,
3D Content, and 3D Software at DAZ3D!</A>
Post a reply to this message
|
|