POV-Ray : Newsgroups : povray.binaries.images : Use of Sam Benge's strand utility Server Time
30 Jul 2024 14:20:42 EDT (-0400)
  Use of Sam Benge's strand utility (Message 11 to 14 of 14)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Cousin Ricky
Subject: Re: Use of Sam Benge's strand utility
Date: 27 Jan 2012 10:25:00
Message: <web.4f22c0c331e1461085de7b680@news.povray.org>
"Samuel Benge" <stb### [at] hotmailcom> wrote:
> The result is... kinda gross. Possibly more animal than plant :/

Reminds me of Cthulhu.


Post a reply to this message

From: Jim Holsenback
Subject: Re: Use of Sam Benge's strand utility
Date: 27 Jan 2012 12:50:05
Message: <4f22e3cd$1@news.povray.org>
On 01/27/2012 02:53 AM, Thomas de Groot wrote:
> On 26-1-2012 23:04, Samuel Benge wrote:
>> OK, here's one.
>
> Oooooooh.....!
>
> You really are a magician, Sam!

LOL ... yes we're not worthy ;-) Nice job Sam!


Post a reply to this message

From: Christian Froeschlin
Subject: Re: Use of Sam Benge's strand utility
Date: 30 Jan 2012 20:55:53
Message: <4f274a29$1@news.povray.org>
Samuel Benge wrote:

> For this image

... very cool image ...

> I took the output from strands.exe and 

... with almost incomprehensible explanation ... ;)

Did I understand correctly that you used povray animation
to implement an iterative 2d filter for thickening the strands
in the height field produces by your strands.exe tool?

> fake subsurface scattering (diffuse-occluding absorbing media)

Sounds interesting, how does it work?

> The water's meniscus

Nice trick ;) Did you compare it to simply rendering the height
data near the water line as water? I suppose the blurring makes
it smoother to give a curved appearance.

> For both the proximity pattern and blurred height data, I used points
> created with Fermat's spiral

Is your proximity pattern sampling in 2d? Or do you generate
points on a sphere for tracing the surface of a 3d object?


Post a reply to this message

From: Samuel Benge
Subject: Re: Use of Sam Benge's strand utility
Date: 31 Jan 2012 17:55:01
Message: <web.4f286ff631e146104264af6e0@news.povray.org>
Thanks for the replies, everyone!

Christian Froeschlin <chr### [at] chrfrde> wrote:
> Samuel Benge wrote:
>
> > I took the output from strands.exe and
>
> ... with almost incomprehensible explanation ... ;)

It's what I do ;)

Let me try again... If you've ever taken a look at the vector analysis macros in
math.inc, you'll have an idea how it works. Those macros pretty much allow you
to determine a gradient's normal or even its falloff rate at any point. When
applied to a function, a variety of effects can be achieved. Since it's better
explained as code, here's the basic setup for pushing a pattern away from
itself:

    #declare PixelSize = 1/image_width;
    #declare Accuracy = 2*PixelSize;
    #declare Amount = 8.0;
    FPgmt(
        x+2*Amount*PixelSize*(FPgmt(x+Accuracy,y,0)-FPgmt(x-Accuracy,y,0)),
        y+2*Amount*PixelSize*(FPgmt(x,y+Accuracy,0)-FPgmt(x,y-Accuracy,0)),
        0
    )

As you can imagine, using five samples quickly becomes expensive if applied
again and again to a function in a single render, which is why I iterate over
pre-rendered data instead.

> Did I understand correctly that you used povray animation
> to implement an iterative 2d filter for thickening the strands
> in the height field produces by your strands.exe tool?

Yep. Same thing I've been doing for a while now, but without all the useless
images stealing HD space :D

> > fake subsurface scattering (diffuse-occluding absorbing media)
>
> Sounds interesting, how does it work?

Absorbing media from one object occludes the diffuse reflection of another:

    sphere{
        0, 1
        pigment{rgb 1}
        finish{brilliance 0}
        double_illuminate
        no_shadow
        hollow
    }

    sphere{
        0, 1.001
        pigment{rgbt 1}
        interior{
            media{
                absorption 4
            }
        }
        hollow
    }

It renders very quickly, but generally doesn't look too great unless big
area_lights are used, which obviously doesn't work for all scenes. There's
probably some light_group trickery that would allow for more flexibility, but I
haven't tried anything along those lines yet. It doesn't play well with
radiosity. And there's also the fact that it requires two objects, one shifted
outward from the other. This makes the technique difficult to use for complex
objects :(

> > The water's meniscus
>
> Nice trick ;) Did you compare it to simply rendering the height
> data near the water line as water? I suppose the blurring makes
> it smoother to give a curved appearance.

I think I've tried that before by placing the height data into an object
pigment, putting that into a normal block, and giving it a highish accuracy. But
the effect just wasn't as nice.

> > For both the proximity pattern and blurred height data, I used points
> > created with Fermat's spiral
>
> Is your proximity pattern sampling in 2d? Or do you generate
> points on a sphere for tracing the surface of a 3d object?

It starts with a sharp, black/white plane function. This is displaced using
height data to make a "height field" function. It is then blurred in 2D (using a
2D point set) and reverse-displaced to make it flat once again. A planar warp is
then applied to make it infinite along the z-axis.

I'll be releasing some new proximity patterns soon, and the 2D version will be
among them so you'll be able to see how it works.

Sam


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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