{"id":159,"date":"2012-05-07T12:04:15","date_gmt":"2012-05-07T12:04:15","guid":{"rendered":"http:\/\/blog.daft-ideas.co.uk\/?p=159"},"modified":"2013-08-01T13:45:03","modified_gmt":"2013-08-01T13:45:03","slug":"perlin-noise","status":"publish","type":"post","link":"https:\/\/blog.daft-ideas.co.uk\/2012\/05\/07\/perlin-noise\/","title":{"rendered":"Perlin Noise"},"content":{"rendered":"

Shamus Young was messing around with Perlin Noise, which turned out to be normal noise. I dug around in an old VM to find this image:<\/p>\n

\"\"<\/a>

Blue and white marble effect. Sort of.<\/p><\/div>\n

The massive sphere in the background is procedurally textured with the Perlin Noise function, that is described in this paper:\u00a0http:\/\/mrl.nyu.edu\/~perlin\/paper445.pdf<\/a><\/p>\n

It’s not the best example I ever produced, but it’s the only build of my old raytracer that I could find. Shame on me for poor version control.<\/p>\n

The source code for it, in Java, is on Ken Perlin’s website here:\u00a0http:\/\/mrl.nyu.edu\/~perlin\/noise\/<\/a><\/p>\n

To be honest, it’s a very long time since I’ve looked at that stage of my ray tracer. I ditched the procedural generation of textures because they took way too long, but the basic idea is that you use the “noise” function, which takes X Y Z coords as arguements, and it returns the “next” noise point from the initial permutation list. Or something. These days I comment my own code a lot better,\u00a0precisely\u00a0because I can’t remember how this stuff works anymore.<\/p>\n

When you’ve got the returned noise amount, you can do cool shit with it. I found a couple of functions around that could turn it into a marble style texture, but you can do a lot more with it.<\/p>\n","protected":false},"excerpt":{"rendered":"

Shamus Young was messing around with Perlin Noise, which turned out to be normal noise. I dug around in an old VM to find this image: The massive sphere in the background is procedurally textured with the Perlin Noise function, that is described in this paper:\u00a0http:\/\/mrl.nyu.edu\/~perlin\/paper445.pdf It’s not the best… Continue reading → <\/span><\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,3],"tags":[57,54],"_links":{"self":[{"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/posts\/159"}],"collection":[{"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/comments?post=159"}],"version-history":[{"count":2,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/posts\/159\/revisions"}],"predecessor-version":[{"id":406,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/posts\/159\/revisions\/406"}],"wp:attachment":[{"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/media?parent=159"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/categories?post=159"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.daft-ideas.co.uk\/wp-json\/wp\/v2\/tags?post=159"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}