|
![](/i/fill.gif) |
Pahidla wrote:
> Hi,
>
> What's the easiest way to display a 2D image, like a phtograph hanging on a
> wall. I've tried something like
>
> box {
> < 10, 20, 5 >
> < 10, 22, 7 >
> pigment {
> image_map {jpeg "puppy.jpg"}
> scale 2
> }
> }
>
> but the box shows gibberish.
>
> Thanks in advance!
>
> Pahidla
>
>
By default, the image is mapped onto the x-y-plane. The image is
projected onto the object as though there were a slide projector
somewhere in the -z-direction. The image exactly fills the square area
from (x,y) coordinates (0,0) to (1,1) regardless of the image's original
size in pixels.
What is mostly done is something like this:
box {
< 0, 0, 0 >
< 1, 1, 1 >
pigment {
image_map {jpeg "puppy.jpg"}
}
scale 2
rotate (if needed)
translate (if needed)
}
Have Fun!
Post a reply to this message
|
![](/i/fill.gif) |