POV-Ray : Newsgroups : povray.general : uv mapping triangles in mesh {} : Re: uv mapping triangles in mesh {} Server Time
18 May 2024 02:11:09 EDT (-0400)
  Re: uv mapping triangles in mesh {}  
From: Josh English
Date: 26 Mar 2023 16:01:42
Message: <6420a4a6$1@news.povray.org>
On 3/26/2023 11:39 AM, Bald Eagle wrote:
> Thomas de Groot <tho### [at] degrootorg> wrote:
> 
>> Phew... I need to ponder this a bit more but this leads to very
>> interesting potential possibilities. I have experience with eval_pigment
>> to do this kind of thing, but this is just a bit smarter. Well done so far.
> 
> Well, what we're doing is instead of just using the underlying pigment value
> returned by eval_pigment directly, we're using that color or grayscale value to
> choose a shape that represents that "brightness".
> 
> You can do it with text (ASCII art), I've done it with the halftone project
> using holes of different sizes (I _cannot_ find the thread), and here I'm going
> to try it with the patterns filling the triangles.
> 
> I got some sleep, got my head screwed on straight, figured out the
> constant-ratio lines, and that got me a bit further along on pattern
> development.
> 
> Now I'm again a little stuck on lines perpendicular to edges, and that also
> hinted that maybe somewhere in the code I have a few things switched around.   I
> have to check once get all the code written, and it could just be a matter of
> swapping #cases of a #switch block.
> 
> Anyhow,  I have most of what I wanted to do completed.  I also noticed the
> overall impression of the assembled patterns is very different depending on
> color choice.  I'll likely have to finish working through the triangle grid code
> to get that all properly converted so that I can rotate triangles, select the
> triangles that fill a rectangle, etc.
> 
> All in all, not bad for a weekend of coding.

That is very cool. You shouldn't need to worry about rotating the 
triangles, just reorder the UV mapping coordinates for the few patterns 
you have where it will make a difference.

--Josh


Post a reply to this message

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