Giter Club home page Giter Club logo

mandelbrotviewer's Introduction

Mandelbrot Viewer

Mandelbrot Viewer is a simple application which utilises the GPU via OpenGL to visualize the Mandelbrot Set in real time. The maximum possible zoom is 64-bit due to the limitations of OpenGL Doubles. v1.0 C++ port of this project

I wrote a tutorial series on how to create this project on my blog which can be found here.

A YouTube video demonstrating the project can be viewed here.

Preview

Preview One Preview Two Preview Three

Building

The application can be built with Maven:

mvn clean package

The jar file will be available in the ./target directory.

Controls

W, A, S, D for panning.

Z, X or scroll wheel for zooming in and out.

K to take a screenshot. (Currently Disabled)

Configuration

GUI

The UI allows you to configure the color and precision of the set via a pure 
java binding of ImGUI. The variables it modifies are the uniform variables u_Color
and u_maxIter used in the fragment shader below.

More useful configuration variables:

src/main/java/Application.java

PIXEL_WIDTH & PIXEL_HEIGHT:
- The window's resolution.
WIDTH & HEIGHT:
- The scale of the complex axis (4 would be [-2, 2]).
TITLE:
- The window's title.
BACKGROUND_COLOUR:
- The window's background colour.

src/resources/shaders/frag.shader

This file contains the math for generating the Mandelbrot Set. 
If you wish to change the colours of the set without the UI you should modify the 
colorFunc function.
It takes in the uniform u_maxIter which is the number of iterations it took before 
the modulus of a point on the set became >= 4.

Libraries

  • LWJGL 3 (minimal OpenGL configuration)
  • JOML (math library)
  • Dear ImGUI (pure java binding of the C++ UI library)

mandelbrotviewer's People

Contributors

cianjinks 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.