<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Procedural Generation on Programmer.ie: Modern AI programming</title>
    <link>http://programmer.ie/categories/procedural-generation/</link>
    <description>Recent content in Procedural Generation on Programmer.ie: Modern AI programming</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Mon, 10 Aug 2026 18:50:00 +0100</lastBuildDate>
    <atom:link href="http://programmer.ie/categories/procedural-generation/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Cellular Automata From First Principles 16: Generate Textures with Local Rules</title>
      <link>http://programmer.ie/post/cellular-automata-from-first-principles-16/</link>
      <pubDate>Mon, 10 Aug 2026 18:50:00 +0100</pubDate>
      <guid>http://programmer.ie/post/cellular-automata-from-first-principles-16/</guid>
      <description>&lt;h1 id=&#34;cellular-automata-from-first-principles-16-generate-textures-with-local-rules&#34;&gt;Cellular Automata From First Principles 16: Generate Textures with Local Rules&lt;/h1&gt;&#xA;&lt;p&gt;Cellular automata do not need to represent a literal physical system.&lt;/p&gt;&#xA;&lt;p&gt;They can also be used as visual machines.&lt;/p&gt;&#xA;&lt;p&gt;The same ingredients we have used throughout the book:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;local state&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;neighborhood perception&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;shared update&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;repetition&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;can generate masks, growth patterns, surface variation and animation.&lt;/p&gt;&#xA;&lt;p&gt;The evaluation question changes.&lt;/p&gt;&#xA;&lt;p&gt;Instead of asking:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Is this physically accurate?&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;we ask:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Does this local process produce useful, controllable visual structure?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cellular Automata From First Principles 15: Grow Terrain from Local Height Rules</title>
      <link>http://programmer.ie/post/cellular-automata-from-first-principles-15/</link>
      <pubDate>Mon, 10 Aug 2026 18:48:00 +0100</pubDate>
      <guid>http://programmer.ie/post/cellular-automata-from-first-principles-15/</guid>
      <description>&lt;h1 id=&#34;cellular-automata-from-first-principles-15-grow-terrain-from-local-height-rules&#34;&gt;Cellular Automata From First Principles 15: Grow Terrain from Local Height Rules&lt;/h1&gt;&#xA;&lt;p&gt;Binary caves ask:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;wall or floor?&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Terrain needs richer state.&lt;/p&gt;&#xA;&lt;p&gt;Let each cell store a height:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;0.0 = low&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;1.0 = high&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now local rules can smooth, raise, erode and classify terrain.&lt;/p&gt;&#xA;&lt;p&gt;The challenge is not creating a pretty array.&lt;/p&gt;&#xA;&lt;p&gt;It is creating a process whose output we can explain and control.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;start-with-a-height-field&#34;&gt;Start with a height field&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; numpy &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; np&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;random_heightmap&lt;/span&gt;(&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    rows&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;120&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    cols&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;160&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    seed&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;42&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;):&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    rng &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; np&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;random&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;default_rng(seed)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; rng&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;random(&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        (rows, cols)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    )&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Raw independent noise contains variation but little large-scale geography.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cellular Automata From First Principles 14: Generate Caves from Noise</title>
      <link>http://programmer.ie/post/cellular-automata-from-first-principles-14/</link>
      <pubDate>Mon, 10 Aug 2026 18:46:00 +0100</pubDate>
      <guid>http://programmer.ie/post/cellular-automata-from-first-principles-14/</guid>
      <description>&lt;h1 id=&#34;cellular-automata-from-first-principles-14-generate-caves-from-noise&#34;&gt;Cellular Automata From First Principles 14: Generate Caves from Noise&lt;/h1&gt;&#xA;&lt;p&gt;A cave generator can be built from a mechanism we already understand:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;random initial cells&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;       ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;count nearby walls&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;       ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;apply local smoothing rule&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;       ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;repeat a few times&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;       ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;stop and use the result&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Unlike a forest-fire simulation, we are not trying to model an indefinitely evolving world.&lt;/p&gt;&#xA;&lt;p&gt;Here the cellular automaton is a &lt;strong&gt;construction process&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
