How is L-systems for road networks modified?

后端 未结 2 1381
有刺的猬
有刺的猬 2021-02-09 05:24

Greetings each and all!

I\'m currently looking into procedural generation of a road network and stumbled upon the L-system algorithm. From what I understand from various

相关标签:
2条回答
  • 2021-02-09 06:01

    So, I've been googling, reading and understanding more the last week and I've found a solution to the problem which I thought I might share. I found this brilliant blog post which basically straightened everything out for me:

    http://www.newton64.ca/blog/?p=747#7472

    That post is based upon another blog post founded here:

    http://mollyrocket.com/forums/viewtopic.php?t=730&sid=a9a2628b059a727cbde67309757ed178

    Now, as far as the L-system goes, I'm not quite sure whether this approach really is an L-system anymore. Sure, there are similarities regarding the iterative process of building the network. In L-systems the string grows over iterations and branches are created using "[" or "]" (atleast in the cases I've seen), and in the approach I'm taking now a while-loop and a priority queue does pretty much the same thing.

    I also would like to point out that I did not fully understand the papers "describing" how to use an L-system for generating a road network, so my reasoning might be a bit off here. But algorithm naming and boundries aside, I found a solution that works for me, which is good for now.

    Happy coding!

    Karl

    0 讨论(0)
  • 2021-02-09 06:19

    I'm the author of the above blog post -- glad you found it useful! I never did get around to finishing Spare Parts -- and if nothing else, I'd have to change the name -- but you've got me thinking about it again.

    Certainly, the algorithm I described probably isn't much of an L-system anymore; importantly, though, I think it's pretty much functionally equivalent. I'm a positivist when it comes to programming, so if it works, compile it!

    EDIT: I've since taken down my old website, but I've recreated the post here. Hope it's still helpful!

    0 讨论(0)
提交回复
热议问题