Ouverture Studio – atelier Lisa Nelson
Le 24 mars 2017 à 18h30, les portes s’ouvriront sur l’atelier et les jeux, invitant le public à jouer de son attention et imagination.
Plus d’info sur le site de charleroi-danse.
Ouverture Studio – atelier Lisa Nelson
Le 24 mars 2017 à 18h30, les portes s’ouvriront sur l’atelier et les jeux, invitant le public à jouer de son attention et imagination.
Plus d’info sur le site de charleroi-danse.
Road network generation: the gif gives you an idea of the procedure executed in ~300 milliseconds by the c++.
With a deformation:
The Polymorph Engine is on itch.io, the go-to community website for sharing, rating and downloading indie games. It sits in the well-named “tools” section where it is already getting some attention.
But we need your help to bring it further. So if you have an itch.io account, be sure to check the Polymorph Engine page, download the install script, give it a 5 stars ratings, or even add it to your favorites.
While you are there, be also sure to check out and follow Frankie and xuv profiles and collections, you might discover some gems.
Let us know about your itch.io profile in the comments. We’ll be sure to check it out.
Different kind of network generated by 3 configurations (images go 2 by 2).
Note: add a variation on the roads length (min, max will be ok).
Result of different configuration of network at each pass. In each image, you see the road network alone and the network with the control grid. I’m proud to mention that the generation time on a big network is taking around 500 millis, something easy to hide with a small transition.
Here, there are 3 + an initial road (the thick one). In each pass, the road becomes smaller and thinner.
It’s also possible to generate the same network with depth enabled. It’s becoming very complex to follow visually, but it makes no mistake 🙂
Reviewing the road generation system.
This random generation merits a bit of attention.
Until now, i was randomly picking a new start point from an existing road to create a new road. The process is consuming, and there is no guarantee to avoid picking several time the same point on the same road.
With the formula above, found in the great numberphile channel (see below), I attribute once and for all a random to each road’s dot. The particularity of this random generation is that it will NEVER repeat two times the same value in one sequence. Once generated, my dots have a number in the range [0,1], with a linear distribution.
For instance, in a line having 10 dots (and therefore 9 segments), each dot will have a random number between 0 and 1. If you order the list of dots by random values, and compare the gap between each sorted values, the average gap will be 0.1!
The way to use this random number is straight forward. If you want to generate a secondary road on 50% of the dot of the first one, you just have to loop over these number and check wherever the random value of the dot is < 0.5. If the distribution was not linear, doing this would not guarantee to create on sub-road every two dots. As it is, you can just specify the percentage, all random calculation has already been done, and in a more controlled way then ofRandomuf() does it.
This formula requires big prime numbers (>10000) to be placed at a and b. Here is the source i used: list of primes.
too look at closely:
flat network (no Z)
slight Z curvature
strong Z curvature
strong Z curvature
strong Z curvature
After a bit of struggle with the management of a 3d grid, the advantage is there: it’s now easy to generate a road network in 3D, with automatic connection of the streets while generating them. It’s a simple brute force & unsupervised generation algorithm, but it is memory efficient and error less.
Just to explain a bit the images above: the cubes are the cells of the road grid. Only the required one are created during road generation. There are connected to each other to speed up the proximity tests once a now road segment is added. I’ll measure the generation time soon, but it’s already quite fast regarding to the first test made several days ago in processing.
Generation of a 3d grid of cells, each one of the cells knows who are the surrounding ones. This to speed up searching around the current cell.
To generate a unique id for each one of the surrounding cell, and quickly find the current cell in the surrounding cell, i used a python that generates a list of enum and a map of opposition. Therefore, when I create a new cell in the grid, its very fast to register it into all the existing ones.
A bit of sight seeing:
Inside buidling:
super low resolution far buidlings:
Orange atmosphere (bg + fog + texture color adapted):
Reply