Giter Site home page Giter Site logo

mandelbrot-renderer's Introduction

Mandelbrot renderer

What it does

This program renders a series of images from the mandelbrot set, a beautiful fractal with very interesting patterns. If you want to learn more about the mathematics behind it, take a look at the Wikipedia entry. The rendered jpeg images can later be concatenated using any video editor of your choice to create a zooming animation.

How it works

Images are rendered using mainly two parameters, namely the zoom and center. The higher the zoom value, the closer we are zoomed in. The center is a complex number specifying which part of the fractal will be at the image's center. The images are rendered in full hd.

Each pixel's color is determined by how often the function fc(z)=z2+c can be applied without diverging (i.e. abs(z) < 2.0). These iterations are massively parallelizable and therefore run on the GPU to gain a significant speed boost using NVIDIA CUDA technology. This means you need a CUDA-compatible GPU to be able to run this program.

We later map the number of iterations of each pixel as a hue angle and convert the resulting HSV color to RGB.

Building

A makefile is provided. In addition to a C++ compiler which will be used as a backend by the nvcc NVIDIA CUDA compiler, you of course need nvcc itself. Just run make and the program will be built.

Usage

All images will be dumped to an images folder. Configuration of values like the zoom, center and image dimensions are done in the source code. Just change the values on the top as you see fit.

mandelbrot-renderer's People

Contributors

baseng0815 avatar

Watchers

James Cloos avatar  avatar

mandelbrot-renderer's Issues

Could you please provide some documents or explanation of codes?

Hi dear author,
It's a great honor to open one issue here, truly honor. I just begin to learn computer graphics and have compiled your program successfully, but it is hard for me to read the codes, could you please provide some explanation or PPT or papers about the code to me? ๐Ÿ‘

thank you
Best Regards with kindness
William

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.