POV-Ray : Newsgroups : povray.binaries.images : Blasted infernal image maps II Server Time
2 Oct 2024 18:18:19 EDT (-0400)
  Blasted infernal image maps II (Message 1 to 9 of 9)  
From: Greg M  Johnson
Subject: Blasted infernal image maps II
Date: 27 Mar 2000 12:27:50
Message: <38df9a16@news.povray.org>
I have an image 126 x 689 pixels. It is the left figure in the following
images.
Help me figure out how to make this thing work.
None of the  following configurations for my box give an image with the
original proportions! Why won't pov do this? Is this a bug?

box{<0,0,0>,<1,1,0.001>
//box{<0,0,0>,<1,689/126,1,0.001>
//box{<0,0,0>,<126/689,1,0.001>
                pigment{
                        image_map{
                                tga "c:\My Documents\left2.tga"
                                once
                                map_type 0
                                }
                        }
                finish {ambient 1 diffuse 0}
                translate <-0.5,-0.5,-0.05>
                scale 14
                translate -17*x -1.5*y  +3*z
        }


Post a reply to this message


Attachments:
Download 'thebody11rebuild3.jpg' (12 KB) Download 'thebody11rebuild2.jpg' (16 KB)

Preview of image 'thebody11rebuild3.jpg'
thebody11rebuild3.jpg

Preview of image 'thebody11rebuild2.jpg'
thebody11rebuild2.jpg


 

From: TonyB
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 13:04:03
Message: <38dfa293@news.povray.org>
Here's how I would do it.

box
{
 -<1,1,0>/2,<1,1,0>/2
 pigment
 {
   image_map
   {
     tga "c:\My Documents\left2"
     once map_type 0 interpolate 2
   }
   translate -<1,1,0>/2
  }
 finish {ambient 1 diffuse 0}
 scale 14 translate <-17,-1.5,3>
}


Post a reply to this message

From: Sigmund Kyrre Aas
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 13:23:44
Message: <38DFA724.5DCE8D96@stud.ntnu.no>
You don't compensate for aspect ratio:

> box{<0,0,0>,<1,1,0.001>
>                 pigment{
>                         image_map{
>                                 tga "c:\My Documents\left2.tga"
>                                 once
>                                 map_type 0
>                                 }
>                         }
>                 finish {ambient 1 diffuse 0}
>                 translate <-0.5,-0.5,-0.05>
                  scale 14 *vnormalize(<126,689,1>)
>                 translate -17*x -1.5*y  +3*z
>         }


Post a reply to this message

From: Greg M  Johnson
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 14:01:09
Message: <38DFAEF8.73E930BE@my-dejanews.com>
Sigmund Kyrre Aas wrote:

> You don't compensate for aspect ratio:
>
> > box{<0,0,0>,<1,1,0.001>

As I said, none of the following first lines give a sensible solution:

box{<0,0,0>,<1,            1,              0.001>
box{<0,0,0>,<1,            689/126,   0.001>
box{<0,0,0>,<126/689, 1,              0.001>


Post a reply to this message

From: Bob Hughes
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 15:05:58
Message: <38dfbf26$1@news.povray.org>
'image_map' is a texture though, so it doesn't matter what the 'box' starts off
as.  You'll always have to scale the texture either within the image map or
pigment or texture part.

Bob

"Greg M. Johnson" <gre### [at] my-dejanewscom> wrote in message
news:38DFAEF8.73E930BE@my-dejanews.com...
| Sigmund Kyrre Aas wrote:
|
| > You don't compensate for aspect ratio:
| >
| > > box{<0,0,0>,<1,1,0.001>
|
| As I said, none of the following first lines give a sensible solution:
|
| box{<0,0,0>,<1,            1,              0.001>
| box{<0,0,0>,<1,            689/126,   0.001>
| box{<0,0,0>,<126/689, 1,              0.001>
|


Post a reply to this message

From: Josh English
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 15:18:08
Message: <38DFC231.28CECC7A@spiritone.com>
> box{<0,0,0>,<1,1,0.001>
>                 pigment{
>                         image_map{
>                                 tga "c:\My Documents\left2.tga"
>                                 once
>                                 map_type 0
>                                 }
>                         }
>                 finish {ambient 1 diffuse 0}
>                 translate <-0.5,-0.5,-0.05>

                   scale <126/689,1,1> /// ***** Added this line

>
>                 scale 14
>                 translate -17*x -1.5*y  +3*z
>         }
>
>   ------------------------------------------------------------------------
>  [Image]  [Image]

--
Josh English
eng### [at] spiritonecom
"May your hopes, dreams, and plans not be destroyed by a few zeros."


Post a reply to this message

From: Sigmund Kyrre Aas
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 15:49:02
Message: <38DFC932.EA41E1AD@stud.ntnu.no>
"Greg M. Johnson" wrote:
> 
> Sigmund Kyrre Aas wrote:
> 
> > You don't compensate for aspect ratio:
> >
> > > box{<0,0,0>,<1,1,0.001>
> 
> As I said, none of the following first lines give a sensible solution:
> 
> box{<0,0,0>,<1,            1,              0.001>
> box{<0,0,0>,<1,            689/126,   0.001>
> box{<0,0,0>,<126/689, 1,              0.001>

Eh. Did you try the changes I made? It should work. According to the manual all
images are mapped from <0,0,0> to <1,1,0>, regardless of the shape mapped onto.
Scaling must come after that, scaling both the object and the image map.


Post a reply to this message

From: David Fontaine
Subject: Re: Blasted infernal image maps II
Date: 27 Mar 2000 17:47:44
Message: <38DFE3FE.2901CD77@faricy.net>
Not sure I fully understand the problem, and someone has probably already told
you this, but:
image_maps are automatically one square unit at the origin. If you need the
map to be a different ratio, are scaling the box later, etc, you must
accordingly put a scale in the pigment block.

--
___     _______________________________________________
 | \     |_          <dav### [at] faricynet> <ICQ 55354965>
 |_/avid |ontaine        http://www.faricy.net/~davidf/

"The only difference between me and a madman is that I'm not mad." -Dali


Post a reply to this message

From: Jerome
Subject: Re: Blasted infernal image maps II
Date: 28 Mar 2000 06:11:27
Message: <38E09350.F6DF43FC@iname.com>
Greg M. Johnson wrote:
> 
> Sigmund Kyrre Aas wrote:
> 
> > You don't compensate for aspect ratio:
> >
> > > box{<0,0,0>,<1,1,0.001>
> 
> As I said, none of the following first lines give a sensible solution:
> 
> box{<0,0,0>,<1,            1,              0.001>
> box{<0,0,0>,<1,            689/126,   0.001>
> box{<0,0,0>,<126/689, 1,              0.001>
	The important change he made is this:
scale 14 *vnormalize(<126,689,1>) instead of scale 14
	(it's lost in the middle of the original message, which is
why you probably overlooked it...)

		Jerome
-- 

* Doctor Jekyll had something * mailto:ber### [at] inamecom
* to Hyde...                  * http://www.enst.fr/~jberger
*******************************


Post a reply to this message

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