|
|
In article <383e7611@news.povray.org> , Nieminen Juha
<war### [at] punarastascstutfi> wrote:
> It certainly looks like a bug. I don't know of any way of printing the
> values of the vector when it has five components so I can't see what's
> happening. There seems to be no way to access the 5th component of a vector
> and #write doesn't work for 5-dimensional vectors for some strange reason.
> 5-dimensional vectors are obviously handled differently from 4 or less
> dimensinal vectors, and perhaps the bug is related to that.
No, you can just treat it as a color:
#declare CapColor=<1,0,0,0,0>;
#macro Cap(Color)
difference
{
union {
cylinder{<0,0,0>,<0,.0889,0>,.17}
cylinder{<0,.0889,0>,<0,.1333,0>,.2}
cylinder{0,y*.0667,.12 translate y*.1333}
}
pigment{ rgbft Color} //Will promote to a 5 component vector
}
#warning "Vector <"
#warning str(Color.red,0,3)
#warning ", "
#warning str(Color.green,0,3)
#warning ", "
#warning str(Color.blue,0,3)
#warning ", "
#warning str(Color.filter,0,3)
#warning ", "
#warning str(Color.transmit,0,3)
#warning "> "
#end
camera { location <0,5,-5> look_at 0 angle 40 }
light_source { 0,rgb 0 translate -z*40 rotate <30,-10,0> }
background { rgb 0}
object { Cap(CapColor) }
Thorsten
____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde
Visit POV-Ray on the web: http://mac.povray.org
Post a reply to this message
|
|