POV-Ray : Newsgroups : povray.binaries.images : Sphere_sweep: gradient along a curve. Server Time
30 Jul 2024 02:18:32 EDT (-0400)
  Sphere_sweep: gradient along a curve. (Message 31 to 40 of 51)  
<<< Previous 10 Messages Goto Latest 10 Messages Next 10 Messages >>>
From: Robert McGregor
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 11 Feb 2014 08:50:00
Message: <web.52fa29ffa5ee4db891114470@news.povray.org>
Le_Forgeron <lef### [at] freefr> wrote:
> Le 11/02/2014 00:14, Robert McGregor a écrit :
>
> > If POV-Ray could auto-calculate UVs on sphere_sweeps at render time, that would
> > be the optimal solution to this... maybe a simple patch can fix it.
>
> Something like u being the "position" on the sphere_sweep and v being
> the circumference ?
> A few questions:
> * for u, what is the range ? 0 to 1 for the whole sphere_sweep, or 0 to
> n-1, n being the number of coordinates ?
> * for v, most complex: how to orient it (where is 0 ?)
>
Exactly: u = spline position, v = circumference

I think a normalized u over 0-1 range for the entire sweep would make texturing
more manageable, using something like:

sphere_sweep {
   ...
   texture { uv_mapping
      pigment {
         gradient u
         color_map { [0 rgb <1,0,0>][1 rgb <0,1,0>]] }
      }
   }
}

The starting position for v shouldn't matter as it's a seamless loop around the
circumference (like cylindrical mapping).

-------------------------------------------------
www.McGregorFineArt.com


Post a reply to this message

From: Le Forgeron
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 11 Feb 2014 09:57:56
Message: <52fa3a74@news.povray.org>
Le 11/02/2014 14:47, Robert McGregor a écrit :
> The starting position for v shouldn't matter as it's a seamless loop around the
> circumference (like cylindrical mapping).

it's not the starting position, it's keeping it coherent along the
various components... maybe a target position such as <0,0,0> to define
the 0, and a clockwise or anticlockwise rotation to increase the value.

Yet it fails when the spheresweep pass through the target position.

Putting the target position at some infinity does not work either, when
the direction of the cylinder/conic is aligned with that direction.

An easy cheating would be u only, v is always 0 (or 0.5), but it's bad.
You can ignore v, but it should be defined... and not constant.

It's also problematic when on a connecting sphere (at one of the vertex).

-- 
Just because nobody complains does not mean all parachutes are perfect.


Post a reply to this message

From: LanuHum
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 11 Feb 2014 12:05:01
Message: <web.52fa579ba5ee4db87a3e03fe0@news.povray.org>
Using Blender and Python I have no problems to receive mesh from hair and to
paint it somehow, using UV
But, the number of hair on the head fluctuates from 100 to 150 thousand.
If 150 000 * 300 = 45 000 000 triangles
It is a lot of for a scene


Post a reply to this message


Attachments:
Download 'curve2mesh.jpg' (105 KB)

Preview of image 'curve2mesh.jpg'
curve2mesh.jpg


 

From: Robert McGregor
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 11 Feb 2014 12:40:01
Message: <web.52fa5fd6a5ee4db891114470@news.povray.org>
"LanuHum" <Lan### [at] yandexru> wrote:
> Using Blender and Python I have no problems to receive mesh from hair and to
> paint it somehow, using UV
> But, the number of hair on the head fluctuates from 100 to 150 thousand.
> If 150 000 * 300 = 45 000 000 triangles
> It is a lot of for a scene

My 300 polygons each was from using a 5-sided profile and 50 segments along the
path, which could easily be a simpler, lighter mesh. But I agree, that is still
far too many polygons, which is why a native sphere_sweep UV solution would be
ideal.

-------------------------------------------------
www.McGregorFineArt.com


Post a reply to this message

From: Robert McGregor
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 12 Feb 2014 13:00:01
Message: <web.52fbb5f6a5ee4db891114470@news.povray.org>
Here is another test, this time using 15,000 sphere_sweeps, each sampling it's
unique color from a photograph of actual hair via eval_pigment(). Added Fresnel
reflections; still very slow to render.
-------------------------------------------------
www.McGregorFineArt.com


Post a reply to this message


Attachments:
Download 'hairtest_spheresweeps.png' (828 KB)

Preview of image 'hairtest_spheresweeps.png'
hairtest_spheresweeps.png


 

From: FractRacer
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 12 Feb 2014 13:03:46
Message: <52fbb782@news.povray.org>

> Here is another test, this time using 15,000 sphere_sweeps, each sampling it's
> unique color from a photograph of actual hair via eval_pigment(). Added Fresnel
> reflections; still very slow to render.
> -------------------------------------------------
> www.McGregorFineArt.com
>
Really awesome, really real. Well done.

-- 
Do not judge my words, judge my actions.

---

http://www.avast.com


Post a reply to this message

From: Thomas de Groot
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 13 Feb 2014 03:38:24
Message: <52fc8480@news.povray.org>
On 12-2-2014 18:57, Robert McGregor wrote:
> Here is another test, this time using 15,000 sphere_sweeps, each sampling it's
> unique color from a photograph of actual hair via eval_pigment(). Added Fresnel
> reflections; still very slow to render.

Your experiments are the best hair simulations I have seen so far. One 
way or another, it would be worthwhile to see if this could be used for 
Poser Hair exports through Poseray: If the /lines/ there could be 
exported as splines, sphere_sweeps would be an easy matter. Hmm, would 
need also an automatic sphere_sweep builder for so many hairs... ;-)

I believe that render speed is not really an issue if the final result 
is astounding.

Thomas


Post a reply to this message

From: Paolo Gibellini
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 13 Feb 2014 06:21:14
Message: <52fcaaaa$1@news.povray.org>
>Robert McGregor  on date 12/02/2014 18.57 wrote:
> Here is another test, this time using 15,000 sphere_sweeps, each sampling it's
> unique color from a photograph of actual hair via eval_pigment(). Added Fresnel
> reflections; still very slow to render.
> -------------------------------------------------
> www.McGregorFineArt.com
>
The growth of the hairs usually is slow...
A beautiful image!
Paolo


Post a reply to this message

From: LanuHum
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 13 Feb 2014 11:55:01
Message: <web.52fcf846a5ee4db87a3e03fe0@news.povray.org>
Thomas de Groot <tho### [at] degrootorg> wrote:

>  Hmm, would need also an automatic sphere_sweep builder for so many hairs... ;-)
>
> I believe that render speed is not really an issue if the final result is
>astounding.
>
> Thomas

Use Blender3D :)


Post a reply to this message

From: Thomas de Groot
Subject: Re: Sphere_sweep: gradient along a curve.
Date: 14 Feb 2014 03:13:25
Message: <52fdd025$1@news.povray.org>
On 13-2-2014 17:52, LanuHum wrote:
> Use Blender3D :)

Yes, I know, but I was thinking of Poser and its hair, /and/ rendering 
in POV-Ray.

Thomas


Post a reply to this message

<<< Previous 10 Messages Goto Latest 10 Messages Next 10 Messages >>>

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