Isotope.Utils (Isotope v0.2.0)

View Source

Utilitary functions for working with noise maps.

Summary

Functions

Shows the given noise map on the stdout using ANSI color codes.

Functions

show_noisemap(noisemap)

@spec show_noisemap(Isotope.Noise.noisemap()) :: :ok

Shows the given noise map on the stdout using ANSI color codes.

This won't work if your terminal doesn't support ANSI color codes.

{:ok, noise} = Isotope.Noise.new()
noise |> Isotope.Noise.noise_map({50, 50})
      |> Isotope.Utils.show_noisemap()
# Outputs noise visualization
:ok