|
![](/i/fill.gif) |
Am 16.07.2010 05:14, schrieb TJ:
> This is my code for the ring(s):
>
> disc
> {
> <0, 40, 0>,
> <-10, 40, -10>,
> 35, 30
> texture
> {
> pigment
> {
> onion
> color_map
> {
> [0.2 rgb<1, 0, 0> transmit 0.8]
> [0.4 rgb<0, 0, 1> transmit 0.3]
> [0.6 rgb<0, 1, 0> transmit 0.3]
> }
> }
> }
> }
POV-Ray doesn't automatically "center" textures on a particular object,
i.e. the center of your onion pigment is still at <0,0,0>, while the
center of your disc is at <0,40,0>.
To compensate for this, you either have to (A) translate the texture
separately, or - which I find easier - (B) initially place the object at
the origin and then translate it around together with its texture:
(A)
disc {
<0,40,0>,
<-10,40,-10>,
35,30
texture {
...
translate <0,40,0>
}
}
(B)
disc {
<0,0,0>,
<-10,40,-10>,
35,30
texture {
...
}
translate <0,40,0>
}
Post a reply to this message
|
![](/i/fill.gif) |