All in One procedural road generation (WIP)

So, I’m in need of geonode setup responsible for procedural road/freeway generation that should handle more advanced connections, intersections and such, very much inspired by this:

Possibly even this, although that might be a bit overkill when it comes to complexity. This is primarily aimed to being used later in a game engine.

This is going to be mainly my diary of that progress and open invitation to anyone who would feel like contributing! I still feel like a beginner in Blender and I’m totally green when it comes to geonodes, but you gotta start somewhere, right? So, let’s see how it goes!

Here’s what it should include (will be expanded over time):

  • simple road/freeway generation
  • smart connections/intersections
  • capable of combining various road structures/bridges/overpasses etc.
  • possibility to stack various attributes for formations (which road type, how many lanes, what props etc.)
  • roundabouts
  • complete freedom over textures
  • also ability to create lines/stripes as extra mesh on top of the road (game development)

Good to haves:

  • ability to create “filler islands” of urban area for urban development for additional building generation, let’s say with Buildify, just more… You know, procedurally.
  • …?

.

Hopefully, I’ll keep posting the progress soon.

Thanks for the reading! Wish me luck!

P.S. I hope I put this into correct category.

6 Likes

If you want to do this project entirely with Geometry Nodes this thread should fit much better in #artwork:works-in-progress

1 Like

Hello !

This seems super exiting, maybe a bit overwhelming to get into geometry nodes.
By each version doing something like that can become easier, but still GN is in it’s very infancy when it comes to working on stuff like that.

It’s kind of weird, because GN are done in a way that it’s probably possible to hack a solution but it can be very tricky.
A good example of that can be this experiment I did :

It’s inspired by a houdini breakdown. Original Houdini version seems much easier to make using loops, at least I get the feeling I could have managed something simpler with maybe blender 4.0 or 5.0 :wink:

All that said, with a little week of work I managed to find my own solution, and most of the time I tend to find a solution but it’s really not easy .

In the meantime, when all the tools are available for want you want to do right away, you can get super cool result really simply, it really depends on the case !

Instead of building everything in one giant nodetree, you can look for a semi-procedural system where you automate some part with GN but still model stuff manually.
Like, you manually place roads , buildings with simple shapes, and your GN tools will add details to that.

Python can also be a great addition, houdini relies a lot on scripting. What you’re doing with nodes you can also do it with a script and in some cases this can be much more convenient, it’s one of the things a bit lacking in GN if we wanted to do more advanced stuff.

But that’s only my opinion, you should definitely make your own and try to solve your problem in your own way !

BTW , there are a few city generator for blender, could be worth looking into how they do stuff !

Good luck and I’m looking forward to see this project evolve !

2 Likes

So, today’s progress was shamelessly copying this guy’s process, to start with basic road plane and generating basic UV map.

This UV is still raster based for now, with a test texture based on one of my prehistoric projects. Btw., I had to switch from 3.2 to 3.3 to be able to see

However, it seems that my initial attempt for doubling/adding the lane (and in that case, there should a function ((or an option)) for mirroring lanes) breaks material.

I’d love to work on it more till the day is over, but having a headache from lack of sleep prevents me from doing so efficiently now. If anyone would like to dive in, here’s the file for You.

road_test_2.blend (2.2 MB)

3 Likes

A bit clunky, but in-depth explanation on how to conver procedural UV coordinates into basic UV map (from curve to mesh).

So, I added a few new values for more user friendly control over the overall shape of the road.

The things I struggle with currently:

  • curb is mirrored, but doesn’t follow the main road
    • when instanced, UV map disappears on this instance
  • UV of the road can’t (?) be set to automatically prolonging by the main curve
    • as a temporary fix, the UV map positioning can be adjust manually
    • again, this process is to be made with exportable UV map for game integration

If anyone would like to take a look into this again, link is below!

test_road_6.blend (2.4 MB)

2 Likes

Really nice job mate! Keep going.