POV-Ray : Newsgroups : povray.general : POV 3.5 ideas : Re: POV 3.5 ideas Server Time
17 Jun 2024 01:08:35 EDT (-0400)
  Re: POV 3.5 ideas  
From: Bob Crispen
Date: 31 May 1999 08:50:33
Message: <37527746.9B5AD869@hiwaay.net>
Bob Hughes wrote:

> Have you looked at the tri-color macro for triangles yet? You may have and
> I'm leading you to old stuff. Anyway, it's at:
> 
> http://www.geocities.com/SiliconValley/Lakes/1434/otherincludes.html
> 
> No idea if this is the same kind of thing you are looking for or not, but
> it does apply a pigment to points on the triangles.

Many thanks, Bob.  That's a feature request I didn't mention, but
which has a very high coolness-per-byte payoff: per-vertex coloring.
I'm off to try it now.

What I had in mind was mapping 2D coordinates of a texture image to
points on a mesh.  The way it's done in VRML is explained at
http://home.hiwaay.net/~crispen/vrmlworks/tutorials/texture.html
There's a fairly spectacular example of texture coordinates at
http://home.hiwaay.net/~crispen/worlds/avatar/bobhead.wrl -- a
friend of mine did this for me last summer at SIGGRAPH.  It's three
photos overlaid on three laser rangefinder scans of my head.

They messed up on my nose -- it doesn't point west quite so much
as it does in one of those meshes, but thanks to texture coordinates,
when I move the points of my nose over, the texture will move with
the points.

Granted that file formats where meshes are central and you have
point sets and indices (Inventor, VRML, lots of others) make the
texture coordinate mapping pretty compact, but compactness doesn't
matter so much in POV.  There's no reason why it couldn't be
applied to the POV notation just like Chris's tri-colour macro.
Instead of rgb value, just specify the texture image for the
triangle and the coordinates within the image for each point.
+-------------------------------+--------------------------------------+
| Rev. Bob "Bob" Crispen        |            "IT FOUND ME!"            |
| cri### [at] hiwaaynet            |      Campus Crusade for Cthulhu      |
+-------------------------------+--------------------------------------+


Post a reply to this message

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