POV-Ray : Newsgroups : povray.animations : image map help : Re: image map help Server Time
28 Jul 2024 12:24:47 EDT (-0400)
  Re: image map help  
From: Bob Hughes
Date: 22 Jun 2000 02:21:46
Message: <3951b07a@news.povray.org>
"Simon Lemieux" <lem### [at] yahoocom> wrote in message
news:39519E01.A91C2599@yahoo.com...
| > this isn't really pertinent to animation, but I was wondering if there
| > is a  way to scale an image map to an object. For instance, if you have
| > a logo you  wanted to put on a modeled piece of paper. Can any1 help?

I'd have to say this is more a general question, or a new user question unless
it has to do with UV mapping to the triangles of a crumpled paper.  If just to
image map a thin box then it's not an advanced kind of question.
Ken Tyler has given a suitable answer at povray.general and there was most
likely no need to ask at these other groups anyway.

| that should go in povray.advanced-users...  the trick is
| image_map {
| <your_image_map_stuff>
| scale <x,y,z>
| }
|
| bingo!

Or boing!  Sorry, I just had to say that :-)
The whole thing hinges upon a corner vector located at <0,0,0> if using the
default planar map type.  Best thing a person can do is read (in Scene Help,
Povray.doc, etc.) about image_map types to understand there use.
It's common practice to translate then scale planar image maps (and bump_map,
etc.) rather than scale then translate.  But that can be up to personal
preference. I.e., box {0,1 pigment {image_map {tga "image.tga" map_type 0} }
scale <160,120,1>} versus doing it like box {<-160,-120,0>,<160,120,1> pigment
{image_map {tga "image.tga" map_type 0} translate -0.5 scale <160,120,1>} } in
order to have everything centered on <0,0,0> instead of the lower-left corner
being the point to reference.
Anyway, you can see how people explaining it might be more cumbersome than
doing a little reading.  However I'm not saying don't ask questions, far from
it.

Bob

| the image will fit to the 1/1 ratio, if your image is 600/200 it will be
scaled
| to 1/1... so you should try:
| scale <1, 1/3,1>
| since the x=1=600 and y=1=600 too... if you know what I mean...
|
| Hope this helps...
| Simon


Post a reply to this message

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