|
|
Francois Labreque wrote in message <3ABFE8FE.6807923E@videotron.ca>...
> in povray.unofficial.patches
>
> test.jpg - done in POV-Ray 3.1g For Windows
> test2.jpg - done in MegaPOV 0.7 for Windows
thanks for effort but try this:
// ============= START
#include "modeling.inc" // whats that ? see description at end of post
#declare SzaryStalowy=texture{pigment{granite color_map{[0 color rgb 0.5][1
color rgb 1]}}finish{ambient 0}scale 5}
#declare Czarny=texture{pigment{color rgb 0}finish{ambient 0}}
#macro RPolygon(P1,P2,P3,P4)
triangle{ P1 P2 P3 }
triangle{ P3 P4 P1 }
#end
#macro RHalfBox(P1,P2)
RPolygon(P1,<P1.x,P1.y,P2.z>,<P1.x,P2.y,P2.z>,<P1.x,P2.y,P1.z>)
RPolygon(P1,<P2.x,P1.y,P1.z>,<P2.x,P2.y,P1.z>,<P1.x,P2.y,P1.z>)
RPolygon(P1,<P2.x,P1.y,P1.z>,<P2.x,P1.y,P2.z>,<P1.x,P1.y,P2.z>)
#end
#macro RBox(P1,P2)
RHalfBox(P1,P2)
RHalfBox(P2,P1)
#end
#macro RCoffer(LOD,X,Y,Z,H,D,T,L,M,R)
#if(LOD)
union{
mesh{
RBox(<-X/2,H,-Z/2>,<X/2,H+Y,Z/2>)
#if(H>0)
RBox(<-(T+D/2),0,T-Z/2>,<-D/2,H,Z/2-T>)
RBox(<D/2,0,T-Z/2>,<T+D/2,H,Z/2-T>)
#end
RPolygon(<-X/2,H+Y-M,R+Z/2>,<X/2,H+Y-M,R+Z/2>,<X/2,H+Y,Z/2>,<-X/2,H+Y,Z/2>)
RPolygon(<-(R+X/2),H+Y-M,M-Z/2>,<-(R+X/2),H+Y-M,Z/2>,<-X/2,H+Y,Z/2>,<-X/2,H+Y,-Z
/2>)
RPolygon(<R+X/2,H+Y-M,M-Z/2>,<R+X/2,H+Y-M,Z/2>,<X/2,H+Y,Z/2>,<X/2,H+Y,-Z/2>)
texture{SzaryStalowy}
}
#local P1=<-L/2,H+Y-M/2,Z/2>;
#local P2=<-L/2,H+Y-M/2,M+Z/2>;
#local P3=<L/2,H+Y-M/2,M+Z/2>;
#local P4=<L/2,H+Y-M/2,Z/2>;
cylinder{P1 P2 R}
sphere{P2 R}
cylinder{P2 P3 R}
sphere{P3 R}
cylinder{P3 P4 R}
texture{Czarny}
}
#else
mesh{
RBox(<-X/2,H,-Z/2>,<X/2,H+Y,Z/2>)
texture{SzaryStalowy}
}
#end
#end
#macro R175(LOD,W175,D175)
#if(!defined(R175Ready))
#local X=W175;
#local Y=1;
#local Z=D175;
#local H=0;
#local D=0;
#local T=0.15;
#local L=0.3;
#local M=0.1;
#local R=T/10;
#declare R175Ready=RCoffer(LOD,X,Y,Z,H,D,T,L,M,R)
#end
R175Ready
#end
#declare Model=R175(HighLOD,0.875,0.5)
#declare Model=object{Model rotate -x*90 texture{SzaryStalowy}}
display_project(Model,0.1,0,3,color rgb 0)
// ============= END
where macro display_project was sended as "modeling enviroment without modeler"
to p.b.utilities as modeling.inc
as attachement here it is output of this object
shouldn't be handle black ?
ABX
Post a reply to this message
Attachments:
Download 'r.png' (34 KB)
Preview of image 'r.png'
|
|