algo

package
v0.0.0-...-b22f1de Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2017 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Overview

Package fractals-go/algo contains the algorithms for computing the pixel values of various fractal images.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fractal

type Fractal interface {
	fmt.Stringer

	// Intensity determines the pixel value of the given
	// coordinates.
	Intensity(x, y float64) uint8

	// ArgHelp provides a help string for use in the UI,
	// telling the user what the arguments to that fractal
	// represent.
	ArgHelp() string
}

Fractal is the interface that decouples the driver program from the particular fractal being rendered.

func NewJuliaExp

func NewJuliaExp(c complex128, depth int, escape float64) Fractal

Returns a new Fractal which computes the Julia variation: e^x + c.

func NewJuliaSq

func NewJuliaSq(c complex128, depth int) Fractal

Returns a new Fractal which computes the Julia variation: x^2 + c.

func NewJuliaZExp

func NewJuliaZExp(c complex128, depth int, escape float64) Fractal

Returns a new Fractal which computes the Julia variation: x*e^x + c.

func NewMandelbrot

func NewMandelbrot(depth int) Fractal

Returns a new Fractal which computes the standard mandelbrot set: x^2 + location.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL