POV-Ray : Newsgroups : povray.advanced-users : uv_map not turning Server Time
30 Jul 2024 04:16:29 EDT (-0400)
  uv_map not turning (Message 1 to 6 of 6)  
From: kane
Subject: uv_map not turning
Date: 9 May 2000 22:38:08
Message: <3918cb90$1@news.povray.org>
Here is the code i'm using to map the image of a face onto a head...

#declare Head = object {head
        uv_mapping texture {
                pigment {
                        image_map {gif "face.gif" }  // face image
                        scale <.8,.9999,.9999>      // scaling the image to
fit the head
                        rotate -23.5*y rotate 9*x  // rotating the image to
position eyes  with eyes, mouth with mouth etc.
                        }
                }
scale 10  // enlarging the head to see it better
rotate 180*y // rotating the head to face the front
}



object {Head
rotate -45*y // attempting to turn the whole head, texture and all

}


I try this and the image stays pointing forward and the head turns, so that
the face is on the side of the head......

any ideas?


Post a reply to this message

From: Gilles Tran
Subject: Re: uv_map not turning
Date: 10 May 2000 10:57:47
Message: <39197873.DAB463AA@inapg.inra.fr>
kane wrote:

>
> I try this and the image stays pointing forward and the head turns, so that
> the face is on the side of the head......
> any ideas?

What kind of object is the head ? There are only a limited number of objects
that support uv mapping in Megapov 0.4 : bicubic_patch, mesh, mesh2, lathe,
sor, sphere and box
Other objects are not supported (but could be) while others, like blobs or
julia fractals, won't be supported (from the Megapov 0.4 doc). Using a uv map
for an unsupported object could give unexpected results.
G.


Post a reply to this message

From: Chris Huff
Subject: Re: uv_map not turning
Date: 10 May 2000 19:04:51
Message: <chrishuff_99-C93A7A.18081310052000@news.povray.org>
In article <3918cb90$1@news.povray.org>, "kane" 
<ann### [at] mindspringcom> wrote:

> Here is the code i'm using to map the image of a face onto a head...
...
> I try this and the image stays pointing forward and the head turns, so 
> that the face is on the side of the head......

I recall seeing some odd-looking code for UV-mapping while writing the 
transform patch(it didn't seem to be transforming the UV-stuff 
correctly), if it is a bug, Nathan probably has already fixed it while 
including my patch.

-- 
Christopher James Huff - Personal e-mail: chr### [at] yahoocom
TAG(Technical Assistance Group) e-mail: chr### [at] tagpovrayorg
Personal Web page: http://chrishuff.dhs.org/
TAG Web page: http://tag.povray.org/


Post a reply to this message

From: Cliff Bowman
Subject: Re: uv_map not turning
Date: 23 May 2000 19:10:53
Message: <392b0ffd@news.povray.org>
"kane" <ann### [at] mindspringcom> wrote in message
news:3918cb90$1@news.povray.org...
> Here is the code i'm using to map the image of a face onto a head...
>
[snipped code]
>
> I try this and the image stays pointing forward and the head turns, so
that
> the face is on the side of the head......
>
> any ideas?
>
I'm with Giles on wanting to know what type of object "head" is. Personally
I tend to include the texture declaration for UV-mapped objects with the
mesh2 declaration of the mesh. E.G.

mesh
{
    smooth_triangle {
        <-0.0277779 , 0.371302 ,-0.0331393 > <-0.0639206 ,-0.152895
,-0.986173 >,
        <-0.0257146 , 0.367395 ,-0.0327338 > < 0.00433927 ,-0.113552
,-0.993523 >,
        <-0.0238329 , 0.370178 ,-0.0331331 > < 0.0084841 ,-0.150033
,-0.988645 >
       uv_vectors
            < 0.638865 , 0.36532 >,< 0.640906 , 0.361171 >,< 0.642727 ,
0.364192 >
    }
...more trianlges...
    smooth_triangle {
        < 0.00102733 , 0.335028 ,-0.00355518 > <-0.112846 ,-0.934316 ,
0.338112 >,
        < 0.000504653 , 0.335198 ,-0.00377561 > <-0.28251 ,-0.900641 ,
0.330201 >,
        < 0.000501327 , 0.337475 , 0.00231839 > <-0.432333 ,-0.855839 ,
0.28395 >
        uv_vectors
            < 0.666954 , 0.328181 >,< 0.666477 , 0.328178 >,< 0.666358 ,
0.327304 >
    }
    uv_mapping
    texture {MyTextureNameHere}
}

and I haven't noticed any problem with UV--POV or MegaPOv (0.3,0.4, and just
started using 0.5). I *did* notice some odd features when trying to do
UV-mapping in official POV (and befor eI got the hang of the syntax used
above) but not since.

Hope this helps (which version of POV are you using BTW?)

Cheers,

Cliff Bowman


Post a reply to this message

From: kane
Subject: Re: uv_map not turning
Date: 23 May 2000 22:23:02
Message: <392b3d06@news.povray.org>
> I'm with Giles on wanting to know what type of object "head" is.
Personally
> I tend to include the texture declaration for UV-mapped objects with the
> mesh2 declaration of the mesh. E.G.

   It was an .obj file converted to .3ds then to pov, in which it was a
union of smooth triangles. I later converted the .obj again to get it into
mesh. So far this hasn't help but thanks for the advice, I try an work with
it some more at a later date when I have more time to fool with it.  Thanks.

> Hope this helps (which version of POV are you using BTW?)

  I'm using MegaPov.


Thanks again,
   Kane


Post a reply to this message

From: Margus Ramst
Subject: Re: uv_map not turning
Date: 23 May 2000 23:24:00
Message: <392B3D7A.64161789@peak.edu.ee>
kane wrote:
> 
>    It was an .obj file converted to .3ds then to pov, in which it was a
> union of smooth triangles. I later converted the .obj again to get it into
> mesh. So far this hasn't help but thanks for the advice, I try an work with
> it some more at a later date when I have more time to fool with it.  Thanks.
> 

Try this link:

http://www.stmuc.com/thbaier/tools.html

Check out 3Dto3D version 4. AFAIK it supports MegaPov's mesh2 format, which can
store uv information, and should therefore work better with uv mapping than
plain mesh.

-- 
Margus Ramst

Personal e-mail: mar### [at] peakeduee
TAG (Team Assistance Group) e-mail: mar### [at] tagpovrayorg


Post a reply to this message

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