Git Product home page Git Product logo

fractal-generator's Introduction

Koch/Julia fractal generator
================================
Entry to the 2014 Functional Programming competition

About the program:
This program does two separate things
	1. Generates Koch snowflake fractals with variable angles and base shapes
	2. Generates simply coloured Julia set fractals.
You can run both of these functions by following the instructions on screen after starting the main function
of the program.

--------
Installation:

The program uses a very nice graphics library called Gloss:
http://gloss.ouroborus.net/

You need to install it by executing:

cabal update
cabal install gloss-examples

This should download and install all the necessary dependencies.
If you get this error -

gloss-raster-1.8.1.2 failed during the building phase. The exception was:
ExitFailure 1

- then try installing llvm:
sudo apt-get install llvm

and do the cabal install again.

-------------
To run it, you need to compile it with:

ghc -threaded --make main.hs

and run:
./main

The koch function won't work when you start it from emacs/ghci or using runghc from terminal, freeglut
will complain about missing fonts.

------------
Controls:

The Koch generator is controlled using arrow keys, numbers 1-3 and some character keys, specific instructions
will be displayed on screen when you run the generator.

fractal-generator's People

Contributors

lcapkovic avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.