POV-Ray : Newsgroups : povray.newusers : Scaling image maps. : Re: Scaling image maps. Server Time
6 Sep 2024 08:11:38 EDT (-0400)
  Re: Scaling image maps.  
From: Mike
Date: 7 Nov 1998 02:14:16
Message: <3643F1B3.47EF83CD@aol.com>
You could look here and save some trouble and learn a new trick:

http://members.xoom.com/POVRAY3/procedural.html

But since you also want a little info on image_mapping, here goes.  I'll
just cover planar mapping.

Since a planar map always starts as a 1 unit wide image projected along the
Z-axis, starting at 0 and extending to Y = 0 and X = 0:

(y)
1
^-------------
|                     |
|                     |
|                     |
0rigin --------> 1  (x)

You probably want to start by centering it on the origin:

translate <-.5, -.5, 0>

Then comes any scaling.  Just make it the size of the object you are placing
it on or maybe a little larger.  Then you can rotate it to line up anyway
you want without worrying about it moving out of place.  Then translate it
and the center will be at the vector you specify, since you centered it to
begin with.

The best tip is to use square images!  That way you don't have to worry
about any lateral distortion, since the image always starts as a square in
POV, whether it was made that way or not.

Another helpful thing to know is that if you use a mask in the paint program
and then save as tga, the transparency will be saved.  This is a very useful
feature.

Hope I provided some insight into image mapping. :)

-Mike

Drew wrote:

> Im trying to make a smiley face sphere for a friend. Im using an image
> map. The problem is that his eyes are spaced too far apart. And well his
> face looks a little distorted in general. Is it possible to scale that
> image map or do I have to draw it right in photoshop? Ive tried putting
> the scaling in various spots. I cant find it in the documentation.
> Besides I want a little insight into how image mapping works.
> Drew


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.