Skip to content

boj/ruby-perlin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Note - November 7th, 2012

This code has been extended, packaged as a gem, and maintained by Bil Bas here.

Ruby Perlin

A Ruby Perlin implementation based off http://freespace.virgin.net/hugo.elias/models/m_perlin.htm

INSTALL

	$ ruby extconf.rb
	$ make

Copy the module to wherever you wish to use it.

USAGE

require 'perlin'

# Takes values Seed, Persistence, and Octaves
p = Perlin.new(123, 1, 1)
# Returns a z value for (x, y)
puts p.run(10, 20) 
# Returns an array of z's for range 
# (x_start, y_start, x_end, y_end)
arr = p.return_chunk(0, 0, 16, 16)

About

Ruby Perlin Noise C Module

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published