|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi,
Following the post from Bill Pragnell, I took time this week end to implement
the wave function collapse algorithm in a POV-Ray script. It's explained in
details in an article on my website:
https://baillehachepascal.dev/2021/pov_wave_collapse.php
and the code is available at the end of the article.
As an example of use, there is a random pendant generator (see image attached).
I hope it will be useful to someone here and hope to see some nice things made
with it. If help is needed I'll be happy to support.
Pascal
Post a reply to this message
Attachments:
Download 'wfcpendants.jpg' (16 KB)
Preview of image 'wfcpendants.jpg'
|
|
| |
| |
|
|
|
|
| |
| |
|
|
hi,
"BayashiPascal" <bai### [at] gmailcom> wrote:
> Following the post from Bill Pragnell, I took time this week end to implement
> the wave function collapse algorithm in a POV-Ray script. It's explained in
> details in an article on my website:
> https://baillehachepascal.dev/2021/pov_wave_collapse.php
> and the code is available at the end of the article.
> As an example of use, there is a random pendant generator (see image attached).
elegant, bottom left is my "favourite". read the web page, v interesting, hope
to find a "week end" to try :-) and sus how it all fits together.
regards, jr.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"BayashiPascal" <bai### [at] gmailcom> wrote:
> the wave function collapse algorithm in a POV-Ray script.
Good writeup! Nice clear explanation, I shall have to come back to this at some
point.
Bill
Post a reply to this message
|
|
| |
| |
|
|
From: Paolo Gibellini
Subject: Re: Wave function collapse algorithm
Date: 18 Nov 2021 05:33:04
Message: <61962be0@news.povray.org>
|
|
|
| |
| |
|
|
Il 14/11/2021 15:05, BayashiPascal ha scritto:
> Hi,
>
> Following the post from Bill Pragnell, I took time this week end to
implement
> the wave function collapse algorithm in a POV-Ray script. It's
explained in
> details in an article on my website:
> https://baillehachepascal.dev/2021/pov_wave_collapse.php
> and the code is available at the end of the article.
> As an example of use, there is a random pendant generator (see image
attached).
> I hope it will be useful to someone here and hope to see some nice
things made
> with it. If help is needed I'll be happy to support.
>
> Pascal
>
Interesting results, you can also develop a road network with your code.
Paolo
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"BayashiPascal" <bai### [at] gmailcom> wrote:
> Hi,
>
> Following the post from Bill Pragnell, I took time this week end to implement
> the wave function collapse algorithm in a POV-Ray script. It's explained in
> details in an article on my website:
> https://baillehachepascal.dev/2021/pov_wave_collapse.php
> and the code is available at the end of the article.
> As an example of use, there is a random pendant generator (see image attached).
> I hope it will be useful to someone here and hope to see some nice things made
> with it. If help is needed I'll be happy to support.
Good work, Pascal. And a nice rundown regarding some contingencies one might
implement for contradicting cells.
I still wonder, though, if square/cube marching might not be more useful for
many similar scenarios. Used in combination with maze-finding algorithms, one
could get some reasonable results.
Downloaded the source. I might just check out your code sometime in the future;
thanks for making it available!
Sam
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Thanks to all for your comments.
Paolo, yes, a road network would be totally feasible. Managing crossroad at
various angles could be challenging though. The rules should rather be
procedurally generated in that case.
Samuel B., marching cube is interesting too. The two algorithms differ by the
way you describe the type of elements in each cell. If you have a function to
express the types according to the coordinates, marching cube is probably the
right solution. If you're in a case where there is no way to express them but to
explicitly list them, the wave function collapse algorithm seem
to me a more appropriate algorithm.
I had just a little more time to play with it and made a celtic knots generator
(code added to the article and result attached below). I'd like to find time for
a small 3D example too, for completion, but it seems improbable...
Pascal
Post a reply to this message
Attachments:
Download 'celticknots.jpg' (65 KB)
Preview of image 'celticknots.jpg'
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On 14/11/2021 15:05, BayashiPascal wrote:
> Hi,
>
> Following the post from Bill Pragnell, I took time this week end to implement
> the wave function collapse algorithm in a POV-Ray script. It's explained in
> details in an article on my website:
> https://baillehachepascal.dev/2021/pov_wave_collapse.php
> and the code is available at the end of the article.
> As an example of use, there is a random pendant generator (see image attached).
> I hope it will be useful to someone here and hope to see some nice things made
> with it. If help is needed I'll be happy to support.
>
> Pascal
>
It looks really very interesting.
Unfortunately the demos don't work :( :(
>> Possible Parse Error: Uncategorized error thrown at /Volumes
>> /WDVrijstuk/PovRayUnofficial_3.8.0-alpha. 10013324-avx source/source
>> /parser/parser_tokenizer.cpp line 2413.
>>
>> Fatal error in parser: Uncategorized error.
>>
>> Render failed
Is it specific to my version ?
--
Kurtz le pirate
Compagnie de la Banquise
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
hi,
kurtz le pirate <kur### [at] gmailcom> wrote:
> ...
> >> Possible Parse Error: Uncategorized error thrown at /Volumes
> >> /WDVrijstuk/PovRayUnofficial_3.8.0-alpha. 10013324-avx source/source
> >> /parser/parser_tokenizer.cpp line 2413.
> >>
> >> Fatal error in parser: Uncategorized error.
> >>
> >> Render failed
>
> Is it specific to my version ?
looks like it, works using alpha.9945627. (there was a recommendation to revert
to earlier alpha if not using the newer beta)
regards, jr.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
kurtz le pirate <kur### [at] gmailcom> wrote:
> It looks really very interesting.
> Unfortunately the demos don't work :( :(
>
> >> Possible Parse Error: Uncategorized error thrown at /Volumes
> >> /WDVrijstuk/PovRayUnofficial_3.8.0-alpha. 10013324-avx source/source
> >> /parser/parser_tokenizer.cpp line 2413.
> >>
> >> Fatal error in parser: Uncategorized error.
> >>
> >> Render failed
>
> Is it specific to my version ?
I'm sorry for that. I'm using 3.8.0-beta.1.unofficial and haven't encountered
this error.
Pascal
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |