|
|
? wrote:
>
> Hello Guys,
>
> I am currently trying to use Pov to make a virtual box, My troube comes
> with the "image_map" functionality .
A planar image_map is by default projected on the XY plane, going from x=0; y=0
to x=1; y=1
In order to apply it to a surface facing up or to the side, you have rotate it
accordingly (or create the object along the XY plane, apply the texture and then
rotate the object in place).
Here's a skeleton example; I'll use polygons for the faces of the box:
#declare Tex=
texture{image_map... translate <-0.5,-0.5,0> scale 2}
//The transformation is there to align the image with the face
#declare Face=
polygon{4, <-1,-1,-1>, <-1,1,-1>, <1,1,-1>, <1,-1,-1>}
union{
object{Face texture{Tex}}
object{Face texture{Tex} rotate y*90}
object{Face texture{Tex} rotate y*-90}
object{Face texture{Tex} rotate x*90}
object{Face texture{Tex} rotate x*-90}
object{Face texture{Tex} rotate x*180}
}
--
Margus Ramst
Personal e-mail: mar### [at] peakeduee
TAG (Team Assistance Group) e-mail: mar### [at] tagpovrayorg
Post a reply to this message
|
|