POV-Ray : Newsgroups : povray.binaries.images : Crackle again Server Time
18 Apr 2024 19:59:26 EDT (-0400)
  Crackle again (Message 11 to 17 of 17)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Bald Eagle
Subject: Re: Crackle again
Date: 24 Nov 2022 14:00:00
Message: <web.637fbe99c37f1de01f9dae3025979125@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:

> I was actually thinking not as an object pattern, but as the native lattice of
> cylinders.  Make a scene with small spheres as the center points, and make the
> Voronoi with cylinder{} objects.

Like so:


Post a reply to this message


Attachments:
Download 'billpragnellvoronoicylindertest.png' (103 KB)

Preview of image 'billpragnellvoronoicylindertest.png'
billpragnellvoronoicylindertest.png


 

From: Bald Eagle
Subject: Re: Crackle again
Date: 24 Nov 2022 14:20:00
Message: <web.637fc2e2c37f1de01f9dae3025979125@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:

> AND, if that's possible - then why not do the Voronoi with prism {} objects.
> Then they can all be collected into an array and textured however one wants -
> even manually, one at a time.

Here's a quick and dirty, scaling each prism height randomly.


Post a reply to this message


Attachments:
Download 'billpragnellvoronoiprismtest.png' (94 KB)

Preview of image 'billpragnellvoronoiprismtest.png'
billpragnellvoronoiprismtest.png


 

From: Bill Pragnell
Subject: Re: Crackle again
Date: 24 Nov 2022 14:35:00
Message: <web.637fc6b2c37f1de0b96893c06f35e431@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> "Bald Eagle" <cre### [at] netscapenet> wrote:
>
> > I was actually thinking not as an object pattern, but as the native lattice
> > of cylinders.  Make a scene with small spheres as the center points, and
> > make the Voronoi with cylinder{} objects.
>
> Like so:

Excellent!

I'm thinking there's scope for some optimization here - removing points between
collinear segments, removing duplicates (for drawing the edges, at least) - this
would make the cells much lighter, and if done at the right stage improve
parsing time.
Coupled with aggregation of max() as you described before (like a binary tree or
similar), this could definitely be improved :)

Different seed shapes would also be interesting.

Bill


Post a reply to this message

From: Bill Pragnell
Subject: Re: Crackle again
Date: 24 Nov 2022 14:35:00
Message: <web.637fc75bc37f1de0b96893c06f35e431@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> Here's a quick and dirty, scaling each prism height randomly.

Even more excellent!

I just need to find some time to play with it myself now :)


Post a reply to this message

From: Bill Pragnell
Subject: Re: Crackle again
Date: 24 Nov 2022 19:30:00
Message: <web.63800bdac37f1de0b96893c06f35e431@news.povray.org>
See p.t.s-f for a macro to generate 2D Voronoi polygons (including collinear
point removal!).

Here's my version of the Voronoi patchwork city :)


Post a reply to this message


Attachments:
Download 'cracklebobs2.png' (462 KB)

Preview of image 'cracklebobs2.png'
cracklebobs2.png


 

From: Bald Eagle
Subject: Re: Crackle again
Date: 25 Nov 2022 20:40:00
Message: <web.63816d6ec37f1de01f9dae3025979125@news.povray.org>
"Bill Pragnell" <bil### [at] hotmailcom> wrote:

> > Also wondering if the Delaunay triangulation can be done as well.  Rendering
> > the dual would be a cool effect.
>
> No idea - this is a bit of a hack! I imagine triangulation could be done with an
> SDL macro, and then the triangles could be colored however you want... but I
> have no experience implementing Delaunay triangulation so I'm not sure.

So, it looks like what happens, is that we draw a line perpendicular to a
Voronoi edge and connect it to another Voronoi center point.

https://web.archive.org/web/20170922181219/http://www.geom.uiuc.edu/~samuelp/del_project.html
(see diagrams at end)

So, somewhere, I know I have the "calculate the closest point on a line to
another point not on the line" macro.  We can use that to create a vector
perpendicular to the line, and then somewhere along that extended vector ought
to be a point in an adjacent cell.

But now I'm thinking that if we are finding the closest point when constructing
the Voronoi, can't we somehow leverage that and draw the line right when we know
our starting center and the just-found closest point?

Much to think about.

We also don't have a Delaunay pattern implemented in POV-Ray, so that would be a
cool thing to add.


Post a reply to this message

From: Paolo Gibellini
Subject: Re: Crackle again
Date: 11 Dec 2022 13:16:01
Message: <63961e61$1@news.povray.org>
Il 25/11/2022 01:27, Bill Pragnell ha scritto:

I like these colors better: a promising image!

Paolo


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

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