In [1]:
import gen_map

In [2]:
block_generator = gen_map.BlockGenerator(seed=0)

In [3]:
help(block_generator.generate_block)


Help on method generate_block in module gen_map:

generate_block(self, idx=0, idy=0, map_size=256) method of gen_map.BlockGenerator instance
    Block generation algorithm using simplex noise


In [4]:
%timeit block_generator.generate_block(0,0,96)


10 loops, best of 3: 31.8 ms per loop

In [5]:
help(gen_map.generate_block)


Help on function generate_block in module gen_map:

generate_block(seed, idx=0, idy=0, map_size=256, octaves=8)
    Block generation algorithm using simplex noise


In [10]:
%timeit gen_map.generate_block(0., 0, 0, 96)


100 loops, best of 3: 11.4 ms per loop

In [7]:
help(gen_map.block_snoise3)


Help on function block_snoise3 in module gen_map:

block_snoise3(seed=0.0, idx=0, idy=0, map_size=96, octaves=8)
    use snoise3 for block generation
    
    seed
        needs to be float. Use z axis of snoise3 as the seed. a whole number
        difference is big enough to not have much in common with the previous
    
    octaves
      increase to increaase detail/roughness


In [9]:
%timeit gen_map.block_snoise3(0., idx=0, idy=0, map_size=96)


100 loops, best of 3: 12.8 ms per loop

noise is about twice as fast as libtcod


In [ ]: